Author: abartlet
Date: 2007-08-10 07:40:50 +0000 (Fri, 10 Aug 2007)
New Revision: 24300

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

Log:
Try to get the LOCAL-EVENT test to pass on hosts with epoll() in
glibc, but not in the host kernel.

Andrew Bartlett


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-08-10 06:55:26 UTC 
(rev 24299)
+++ branches/SAMBA_4_0/source/torture/local/event.c     2007-08-10 07:40:50 UTC 
(rev 24300)
@@ -97,9 +97,17 @@
 
        t = timeval_current();
        while (!finished) {
+               errno = 0;
                if (event_loop_once(ev_ctx) == -1) {
                        talloc_free(ev_ctx);
-                       torture_fail(test, "Failed event loop\n");
+                       if (errno == ENOSYS) {
+                               torture_comment(test, "Host kernel does not 
support %s event backend!", backend);
+                               talloc_free(ev_ctx);
+                               
+                               return true;
+                       } else {
+                               torture_fail(test, "Failed event loop\n");
+                       }
                }
        }
 

Reply via email to