]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3: smbd: Always use metadata_fsp() when processing fsctls.
authorJeremy Allison <jra@samba.org>
Thu, 10 Nov 2022 22:43:15 +0000 (14:43 -0800)
committerJule Anger <janger@samba.org>
Mon, 23 Jan 2023 10:01:59 +0000 (10:01 +0000)
Currently all fsctls we implement need the base fsp, not
an alternate data stream fsp. We may revisit this later
if we implement fsctls that operate on an ADS.

Remove knownfail.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=15236

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andrew Walker <awalker@ixsystems.com>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Mon Nov 14 18:13:31 UTC 2022 on sn-devel-184

(cherry picked from commit fa4eba131b882c3858b28f5fd9864998e19a4510)

selftest/knownfail.d/smb2-ioctl-stream [deleted file]
source3/modules/vfs_default.c

diff --git a/selftest/knownfail.d/smb2-ioctl-stream b/selftest/knownfail.d/smb2-ioctl-stream
deleted file mode 100644 (file)
index 518726e..0000000
+++ /dev/null
@@ -1 +0,0 @@
-^samba3.smb2.ioctl-on-stream.ioctl-on-stream\(fileserver\)
index c67845383539e77986e5b70fd12c9050bc73da21..0be634ce4c24154b34451d79b31cf6d80a055394 100644 (file)
@@ -1392,7 +1392,13 @@ static NTSTATUS vfswrap_fsctl(struct vfs_handle_struct *handle,
        char **out_data = (char **)_out_data;
        NTSTATUS status;
 
-       SMB_ASSERT(!fsp_is_alternate_stream(fsp));
+       /*
+        * Currently all fsctls operate on the base
+        * file if given an alternate data stream.
+        * Revisit this if we implement fsctls later
+        * that need access to the ADS handle.
+        */
+       fsp = metadata_fsp(fsp);
 
        switch (function) {
        case FSCTL_SET_SPARSE: