+2016-04-19 Samuel Thibault <samuel.thibault@ens-lyon.org>
+
+ * sysdeps/mach/hurd/profil.c (update_waiter): Initialize
+ profil_reply_port.
+ (profile_waiter): Do not initialize profil_reply_port.
+
2016-04-18 Wilco Dijkstra <wdijkstr@arm.com>
[BZ #18712]
static int profile_tick;
/* Reply port used by profiler thread */
-static mach_port_t profil_reply_port;
+static mach_port_t profil_reply_port = MACH_PORT_NULL;
/* Forwards */
static kern_return_t profil_task_get_sampled_pcs (mach_port_t,
if (profile_thread == MACH_PORT_NULL)
{
+ if (profil_reply_port == MACH_PORT_NULL)
+ profil_reply_port = __mach_reply_port ();
/* Set up the profiling collector thread. */
err = __thread_create (__mach_task_self (), &profile_thread);
if (! err)
mach_msg_header_t msg;
mach_port_t timeout_reply_port;
- profil_reply_port = __mach_reply_port ();
timeout_reply_port = __mach_reply_port ();
while (1)