X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fcommon%2Fconsumer.c;h=e0a756a5697c40c7cbbd1ff0887a5c01f61464e3;hp=61d6f2e79b702337e3e8095da5132136714616b5;hb=d7b75ec82e5affcfec20e4bc6b208648aa0f58ba;hpb=20275fe8f99ff582686a0defbd88de971c98450c diff --git a/src/common/consumer.c b/src/common/consumer.c index 61d6f2e79..e0a756a56 100644 --- a/src/common/consumer.c +++ b/src/common/consumer.c @@ -1325,7 +1325,15 @@ static int write_relayd_metadata_id(int fd, ret = write(fd, (void *) &hdr, sizeof(hdr)); } while (ret < 0 && errno == EINTR); if (ret < 0) { - PERROR("write metadata stream id"); + /* + * This error means that the fd's end is closed so ignore the perror + * not to clubber the error output since this can happen in a normal + * code path. + */ + if (errno != EPIPE) { + PERROR("write metadata stream id"); + } + DBG3("Consumer failed to write relayd metadata id (errno: %d)", errno); goto end; } DBG("Metadata stream id %" PRIu64 " with padding %lu written before data",