diff --git a/WHATS_NEW b/WHATS_NEW index 24c17fa42..33ca60200 100644 --- a/WHATS_NEW +++ b/WHATS_NEW @@ -1,5 +1,7 @@ Version 2.02.94 - ==================================== + Better detection of missing dmeventd fifo connection (2.02.93). + Add some close() and dev_close() error path backtraces. For polling daemon reopen stdin,stdout,stderr to /dev/null. Limit the max size of processed clvmd message to ~8KB. Do not send uninitilised bytes in cluster error reply messages. diff --git a/daemons/dmeventd/libdevmapper-event.c b/daemons/dmeventd/libdevmapper-event.c index 39324b1f3..4237efb8f 100644 --- a/daemons/dmeventd/libdevmapper-event.c +++ b/daemons/dmeventd/libdevmapper-event.c @@ -232,7 +232,6 @@ static int _daemon_read(struct dm_event_fifos *fifos, size_t size = 2 * sizeof(uint32_t); /* status + size */ uint32_t *header = alloca(size); char *buf = (char *)header; - struct stat fstatbuf; while (bytes < size) { for (i = 0, ret = 0; (i < 20) && (ret < 1); i++) { @@ -246,11 +245,8 @@ static int _daemon_read(struct dm_event_fifos *fifos, log_error("Unable to read from event server"); return 0; } - /* Check whether fifo is still alive */ - if ((ret == 0) && - fstat(fifos->server + 1, &fstatbuf) && - (errno == EBADF)) { - log_error("Fifo fd is bad for event server."); + if ((ret == 0) && i && !bytes) { + log_error("No input from event server."); return 0; } }