From: Jérémie Galarneau Date: Thu, 13 Jun 2019 18:41:48 +0000 (-0400) Subject: Fix: don't hide EBADF error subbuffer write X-Git-Url: http://git.efficios.com/?p=lttng-tools.git;a=commitdiff_plain;h=fcf0f774e2b567e5dcf9190a84973b7a4e06eb7d Fix: don't hide EBADF error subbuffer write There are _no_ legitimate circumstances where a "EBADF" error should be considered normal in a multi-threaded program. This doesn't fix a known problem, but it hid an error while testing a development branch. It is considered a fix since not logging this error can make debugging more difficult if this was, in fact, hiding a problem. Signed-off-by: Jérémie Galarneau --- diff --git a/src/common/consumer/consumer.c b/src/common/consumer/consumer.c index 7a7f7954b..efafeddbc 100644 --- a/src/common/consumer/consumer.c +++ b/src/common/consumer/consumer.c @@ -1856,7 +1856,7 @@ ssize_t lttng_consumer_on_read_subbuffer_mmap( relayd_hang_up = 1; /* Socket operation failed. We consider the relayd dead */ - if (errno == EPIPE || errno == EINVAL || errno == EBADF) { + if (errno == EPIPE) { /* * This is possible if the fd is closed on the other side * (outfd) or any write problem. It can be verbose a bit for a