summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/lsdistcc.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/lsdistcc.c b/src/lsdistcc.c
index 8bae7c8..a8d4ee1 100644
--- a/src/lsdistcc.c
+++ b/src/lsdistcc.c
@@ -720,6 +720,10 @@ static int one_poll_loop(struct rslave_s* rs, struct state_s states[],
* and make the program take longer than it should.
*/
nready = poll(pollfds, (unsigned)nfds, 50);
+ if (nready == -1) {
+ fprintf(stderr, "lsdistcc: poll failed: %s\n", strerror(errno));
+ exit(1);
+ }
gettimeofday(&now, 0);