From: Pierre-Marc Fournier Date: Fri, 12 Jun 2009 05:41:10 +0000 (-0400) Subject: tracectl.c: send error when put_subbuf fails X-Git-Tag: v1.9.1~993 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=0a58610fc313f7f8a0d7be5ac56154a56ab7a79f;p=lttng-ust.git tracectl.c: send error when put_subbuf fails this happens when the reader is pushed by a write --- diff --git a/libust/tracectl.c b/libust/tracectl.c index 3b9d3d39..8be2cd03 100644 --- a/libust/tracectl.c +++ b/libust/tracectl.c @@ -570,12 +570,13 @@ int listener_main(void *p) result = ltt_do_put_subbuf(rbuf, lttbuf, consumed_old); if(result < 0) { - WARN("ltt_do_put_subbuf: error"); + WARN("ltt_do_put_subbuf: error (subbuf=%s)", channel_name); + asprintf(&reply, "%s", "ERROR", consumed_old); } else { - DBG("ltt_do_put_subbuf: success"); + DBG("ltt_do_put_subbuf: success (subbuf=%s)", channel_name); + asprintf(&reply, "%s", "OK", consumed_old); } - asprintf(&reply, "%s", "OK", consumed_old); result = ustcomm_send_reply(&ustcomm_app.server, reply, &src); if(result) {