pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-uecups/+/27738 )
Change subject: main.c: Improve logging ......................................................................
main.c: Improve logging
Change-Id: I6d9a355fef78906cee1ddf65ebb00a738b43c596 --- M daemon/main.c 1 file changed, 4 insertions(+), 0 deletions(-)
Approvals: Jenkins Builder: Verified fixeria: Looks good to me, approved
diff --git a/daemon/main.c b/daemon/main.c index 328d074..76aeab5 100644 --- a/daemon/main.c +++ b/daemon/main.c @@ -72,6 +72,8 @@ /* kill the specified subprocess and forget about it */ static void subprocess_destroy(struct subprocess *p, int signal) { + LOGCC(p->cups_client, LOGL_DEBUG, "Kill subprocess pid %llu with signal %u\n", + (unsigned long long)p->pid, signal); kill(p->pid, signal); llist_del(&p->list); talloc_free(p); @@ -478,6 +480,7 @@ struct subprocess *p, *p2; json_t *jres;
+ LOGCC(cc, LOGL_DEBUG, "Destroying all tunnels\n"); pthread_rwlock_wrlock(&d->rwlock); llist_for_each_entry_safe(t, t2, &d->gtp_tunnels, list) { _gtp_tunnel_destroy(t); @@ -485,6 +488,7 @@ pthread_rwlock_unlock(&d->rwlock);
/* no locking needed as this list is only used by main thread */ + LOGCC(cc, LOGL_DEBUG, "Destroying all subprocesses\n"); llist_for_each_entry_safe(p, p2, &d->subprocesses, list) { subprocess_destroy(p, SIGKILL); }