]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Don't destroy a manager session if poll() returns an error of EAGAIN.
authorRussell Bryant <russell@russellbryant.com>
Fri, 18 Apr 2008 21:48:06 +0000 (21:48 +0000)
committerRussell Bryant <russell@russellbryant.com>
Fri, 18 Apr 2008 21:48:06 +0000 (21:48 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@114284 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/manager.c

index 10a00a79595a6422d9fc3ed06c27f9386c1746bb..3204edad8dfcbe88843246b34d9316df54e262f3 100644 (file)
@@ -2217,7 +2217,7 @@ static int get_input(struct mansession *s, char *output)
                s->waiting_thread = AST_PTHREADT_NULL;
                ast_mutex_unlock(&s->__lock);
                if (res < 0) {
-                       if (errno == EINTR) {
+                       if (errno == EINTR || errno == EAGAIN) {
                                return 0;
                        }
                        ast_log(LOG_WARNING, "Select returned error: %s\n", strerror(errno));