diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2007-12-02 19:45:45 +0000 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2007-12-02 19:45:45 +0000 |
commit | 67a456891b99d8ec352a3fc4851c111302a689ae (patch) | |
tree | e7f09c54d71f969ab907f75c9ee649886717075d /src/lwp.c | |
parent | e977beb1d71d48ae7dc728dccf30232509de28b5 (diff) |
Send pid everytime and ignore children (for now...)
Diffstat (limited to 'src/lwp.c')
-rw-r--r-- | src/lwp.c | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -137,6 +137,7 @@ _lwp_write_events (const LWP_EventRecord *events, guint n_events) struct sockaddr_un addr; int sk; guint32 time; + pid_t pid; guint n; const char *env; LWP_Symbol *ip; @@ -160,6 +161,10 @@ _lwp_write_events (const LWP_EventRecord *events, guint n_events) if (! _lwp_writen (sk, "LWP", 4)) goto CLEAN_SK; + pid = getpid(); + if (! _lwp_writen (sk, &pid, sizeof (pid))) + goto CLEAN_SK; + time = _lwp_read_time (); if (! _lwp_writen (sk, &time, sizeof (time))) goto CLEAN_SK; @@ -227,10 +232,6 @@ _lwp_write_events (const LWP_EventRecord *events, guint n_events) switch (events[n].type) { case LWP_INIT: - if (! _lwp_writen (sk, &ev->init.pid, sizeof (ev->init.pid))) - { - goto CLEAN_SK; - } break; case LWP_FINI: @@ -622,7 +623,6 @@ __lwp_init (void) if (_lwp_initialized++) return; - event.init.pid = getpid(); _lwp_record_event (LWP_INIT, &event); _lwp_events_initialized = TRUE; |