s4-torture: Add function declarations to lease_break_handler.h
authorSachin Prabhu <sprabhu@redhat.com>
Sat, 16 Mar 2019 12:11:04 +0000 (12:11 +0000)
committerJeremy Allison <jra@samba.org>
Fri, 19 Apr 2019 17:27:12 +0000 (17:27 +0000)
Do not completely depend on proto.h.

Also move torture_reset_break_info() to lease_break_handler.h so that
the layout is similar to that of oplock_break_handler.*

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/lease_break_handler.h

index b70234420bdc3bc75571d6adaebec2806ab89a23..5f8e325d63f97a2672410d6ddc76e7011e6cad43 100644 (file)
@@ -124,11 +124,3 @@ done:
 
        return;
 }
-
- void torture_reset_lease_break_info(struct torture_context *tctx,
-                                    struct lease_break_info *r)
-{
-       ZERO_STRUCTP(r);
-       r->tctx = tctx;
-}
-
index dc8841bb8a1c10ef616daabc77fecd89b63e2a48..1e915e27951cd7271aee4c3433d37fabdb1f6579 100644 (file)
@@ -118,5 +118,14 @@ struct lease_break_info {
 
 extern struct lease_break_info lease_break_info;
 
-void torture_reset_lease_break_info(struct torture_context *tctx,
-                                   struct lease_break_info *r);
+bool torture_lease_handler(struct smb2_transport *transport,
+                          const struct smb2_lease_break *lb,
+                          void *private_data);
+void torture_wait_for_lease_break(struct torture_context *tctx);
+
+static inline void torture_reset_lease_break_info(struct torture_context *tctx,
+                                                 struct lease_break_info *r)
+{
+       ZERO_STRUCTP(r);
+       r->tctx = tctx;
+}