s4-torture: Increase timeout for lease/oplock break handlers
authorSachin Prabhu <sprabhu@redhat.com>
Mon, 28 May 2018 11:54:54 +0000 (17:24 +0530)
committerJeremy Allison <jra@samba.org>
Fri, 19 Apr 2019 17:27:13 +0000 (17:27 +0000)
0.1 seconds is not enough when running tests against a server over the
network and are causing timing related bugs. We increase this to 1
second.

Signed-off-by: Sachin Prabhu <sprabhu@redhat.com>
Reviewed-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source4/torture/smb2/lease_break_handler.c
source4/torture/smb2/oplock_break_handler.c

index 8e576391eb13b62bae69731de32607fd4b31d9be..d741127f3d591b70a6004f32ffec783bb30c7936 100644 (file)
@@ -108,8 +108,8 @@ void torture_wait_for_lease_break(struct torture_context *tctx)
        bool timesup = false;
        int old_count = lease_break_info.count;
 
-       /* Wait .1 seconds for an lease break */
-       ne = tevent_timeval_current_ofs(0, 100000);
+       /* Wait 1 second for an lease break */
+       ne = tevent_timeval_current_ofs(0, 1000000);
 
        te = tevent_add_timer(tctx->ev, tmp_ctx, ne, timeout_cb, &timesup);
        if (te == NULL) {
index de46eb32f2a90e8e8c89c1ad1db5c47b05fd7f6a..d64b0bed6dbdb7cd019e1f0f9874f978f91215b2 100644 (file)
@@ -125,8 +125,8 @@ void torture_wait_for_oplock_break(struct torture_context *tctx)
        bool timesup = false;
        int old_count = break_info.count;
 
-       /* Wait .1 seconds for an oplock break */
-       ne = tevent_timeval_current_ofs(0, 100000);
+       /* Wait 1 second for an oplock break */
+       ne = tevent_timeval_current_ofs(0, 1000000);
 
        te = tevent_add_timer(tctx->ev, tmp_ctx, ne, timeout_cb, &timesup);
        if (te == NULL) {