]> granicus.if.org Git - libevent/commitdiff
Oops; fix the *right* windows compile issue
authorNick Mathewson <nickm@torproject.org>
Thu, 3 May 2012 16:15:11 +0000 (12:15 -0400)
committerNick Mathewson <nickm@torproject.org>
Thu, 3 May 2012 16:15:11 +0000 (12:15 -0400)
test/regress.c

index 25d9a884df9f33ddce6ab17f743565681c7d4534..65921420ba37b48b92f15307ad9458703d316b6f 100644 (file)
@@ -639,7 +639,11 @@ test_persistent_timeout_jump(void *ptr)
        event_assign(&ev, data->base, -1, EV_PERSIST, periodic_timeout_cb, &count);
        event_add(&ev, &msec100);
        /* Wait for a bit */
+#ifdef _WIN32
+       Sleep(1000);
+#else
        sleep(1);
+#endif
        event_base_loopexit(data->base, &msec50);
        event_base_dispatch(data->base);
        tt_int_op(count, ==, 1);
@@ -878,11 +882,7 @@ test_fork(void)
        }
 
        /* wait for the child to read the data */
-#ifdef _WIN32
-       Sleep(1000);
-#else
        sleep(1);
-#endif
 
        if (write(pair[0], TEST1, strlen(TEST1)+1) < 0) {
                tt_fail_perror("write");