Merged revisions 114284 via svnmerge from
authorRussell Bryant <russell@russellbryant.com>
Fri, 18 Apr 2008 21:51:05 +0000 (21:51 +0000)
committerRussell Bryant <russell@russellbryant.com>
Fri, 18 Apr 2008 21:51:05 +0000 (21:51 +0000)
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r114284 | russell | 2008-04-18 16:48:06 -0500 (Fri, 18 Apr 2008) | 2 lines

Don't destroy a manager session if poll() returns an error of EAGAIN.

........

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@114285 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/manager.c

index 69a889b..8825010 100644 (file)
@@ -2847,7 +2847,7 @@ static int get_input(struct mansession *s, char *output)
                /* If we get a signal from some other thread (typically because
                 * there are new events queued), return 0 to notify the caller.
                 */
-               if (errno == EINTR)
+               if (errno == EINTR || errno == EAGAIN)
                        return 0;
                ast_log(LOG_WARNING, "poll() returned error: %s\n", strerror(errno));
                return -1;