--- asterisk-orig/manager.c 2005-08-07 17:59:47.170199165 +0200 +++ asterisk/manager.c 2005-08-07 18:04:38.043471188 +0200 @@ -1301,6 +1301,7 @@ res = poll(fds, 1, -1); if (res < 0) { ast_log(LOG_WARNING, "Select returned error: %s\n", strerror(errno)); + return -1; } else if (res > 0) { ast_mutex_lock(&s->lock); res = read(s->fd, s->inbuf + s->inlen, sizeof(s->inbuf) - 1 - s->inlen);