[asterisk-commits] file: branch 1.4 r50602 - /branches/1.4/main/manager.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Fri Jan 12 09:42:34 MST 2007


Author: file
Date: Fri Jan 12 10:42:33 2007
New Revision: 50602

URL: http://svn.digium.com/view/asterisk?view=rev&rev=50602
Log:
We need to check for res being 0 in do_message itself, otherwise our headers will get lost.

Modified:
    branches/1.4/main/manager.c

Modified: branches/1.4/main/manager.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/main/manager.c?view=diff&rev=50602&r1=50601&r2=50602
==============================================================================
--- branches/1.4/main/manager.c (original)
+++ branches/1.4/main/manager.c Fri Jan 12 10:42:33 2007
@@ -2060,7 +2060,9 @@
 
 	for (;;) {
 		res = get_input(s, header_buf);
-		if (res > 0) {
+		if (res == 0) {
+			continue;
+		} else if (res > 0) {
 			/* Strip trailing \r\n */
 			if (strlen(header_buf) < 2)
 				continue;
@@ -2086,9 +2088,7 @@
 	for (;;) {
 		res = do_message(s);
 		
-		if (res == 0) {
-			continue;
-		} else if (res < 0) {
+		if (res < 0) {
 			break;
 		} else if (s->eventq->next) {
 			if (process_events(s))



More information about the asterisk-commits mailing list