s4:torture:smb2:maxwrite: compile maxwrite test at least.
authorGünther Deschner <gd@samba.org>
Fri, 26 Feb 2016 16:25:58 +0000 (17:25 +0100)
committerGünther Deschner <gd@samba.org>
Wed, 7 Sep 2016 10:09:16 +0000 (12:09 +0200)
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Uri Simchoni <uri@samba.org>
source4/torture/smb2/connect.c
source4/torture/smb2/maxwrite.c
source4/torture/smb2/wscript_build

index cbfad2408f72c23dc9bf29d954f8f10f17b97820..063b298c1dfd101686205935c9c8dee4063bf210 100644 (file)
@@ -139,10 +139,10 @@ static NTSTATUS torture_smb2_write(struct torture_context *tctx, struct smb2_tre
 /*
   send a create
 */
-static NTSTATUS torture_smb2_createfile(struct torture_context *tctx,
-                                       struct smb2_tree *tree,
-                                       const char *fname,
-                                       struct smb2_handle *handle)
+NTSTATUS torture_smb2_createfile(struct torture_context *tctx,
+                                struct smb2_tree *tree,
+                                const char *fname,
+                                struct smb2_handle *handle)
 {
        struct smb2_create io;
        NTSTATUS status;
index c9dede9fe385bfa9b94ee42d25e7c9ed999bd8a2..bc52ebc41d9f59dca285b6de7f7f6a8158655445 100644 (file)
@@ -74,7 +74,12 @@ static NTSTATUS torture_smb2_write(struct torture_context *tctx,
                                        return NT_STATUS_NET_WRITE_FAULT;
                                }
                        }
-                       handle = torture_smb2_create(tree, FNAME);
+                       status = torture_smb2_createfile(tctx, tree, FNAME, &handle);
+                       if (!NT_STATUS_IS_OK(status)) {
+                               torture_comment(tctx, "failed to create file handle\n");
+                               talloc_free(tmp_ctx);
+                               return status;
+                       }
                        continue;
                } else {
                        min = len;
index a2e27db0212b17c4a9c500405c0aa8741bb79e48..ba7a9bd6d47ec009b5efedea5288a8aa5e13f7e2 100644 (file)
@@ -16,6 +16,7 @@ bld.SAMBA_MODULE('TORTURE_SMB2',
         lease.c
         lock.c
         maxfid.c
+        maxwrite.c
         notify.c
         notify_disabled.c
         oplock.c