svn commit: samba r20990 - in branches/SAMBA_4_0/source/torture/local: .

tridge at samba.org tridge at samba.org
Wed Jan 24 04:30:45 GMT 2007


Author: tridge
Date: 2007-01-24 04:30:44 +0000 (Wed, 24 Jan 2007)
New Revision: 20990

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=20990

Log:

check for errors from event_loop_once()

Modified:
   branches/SAMBA_4_0/source/torture/local/event.c


Changeset:
Modified: branches/SAMBA_4_0/source/torture/local/event.c
===================================================================
--- branches/SAMBA_4_0/source/torture/local/event.c	2007-01-24 04:28:17 UTC (rev 20989)
+++ branches/SAMBA_4_0/source/torture/local/event.c	2007-01-24 04:30:44 UTC (rev 20990)
@@ -98,7 +98,11 @@
 
 	t = timeval_current();
 	while (!finished) {
-		event_loop_once(ev_ctx);
+		if (event_loop_once(ev_ctx) == -1) {
+			torture_fail(test, "Failed event loop\n");
+			talloc_free(ev_ctx);
+			return False;
+		}
 	}
 
 	talloc_free(fde);
@@ -106,7 +110,9 @@
 	close(fd[1]);
 
 	while (alarm_count < fde_count+1) {
-		event_loop_once(ev_ctx);
+		if (event_loop_once(ev_ctx) == -1) {
+			break;
+		}
 	}
 
 	torture_comment(test, "Got %.2f pipe events/sec\n", fde_count/timeval_elapsed(&t));



More information about the samba-cvs mailing list