s3: VFS: vfs_streams_depot: Rename streams_depot_rmdir() to streams_depot_rmdir_inter...
authorJeremy Allison <jra@samba.org>
Fri, 4 Oct 2019 22:12:30 +0000 (15:12 -0700)
committerRalph Boehme <slow@samba.org>
Thu, 10 Oct 2019 06:09:39 +0000 (06:09 +0000)
Make rmdir_fn() a wrapper function. This will
allow us to add the dirfsp parameter.

Fix DEBUG statement so it doesn't print the wrong function name.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
source3/modules/vfs_streams_depot.c

index 5be72fc1835e1650173b42f95b8521310ba91440..02b0fdf54149464819f972b05b66adbb07ee3e2a 100644 (file)
@@ -740,14 +740,13 @@ static int streams_depot_unlink_internal(vfs_handle_struct *handle,
        return ret;
 }
 
-static int streams_depot_rmdir(vfs_handle_struct *handle,
+static int streams_depot_rmdir_internal(vfs_handle_struct *handle,
                                const struct smb_filename *smb_fname)
 {
        struct smb_filename *smb_fname_base = NULL;
        int ret = -1;
 
-       DEBUG(10, ("streams_depot_rmdir called for %s\n",
-               smb_fname->base_name));
+       DBG_DEBUG("called for %s\n", smb_fname->base_name);
 
        /*
         * We potentially need to delete the per-inode streams directory
@@ -821,7 +820,7 @@ static int streams_depot_unlinkat(vfs_handle_struct *handle,
        int ret;
        SMB_ASSERT(dirfsp == dirfsp->conn->cwd_fsp);
        if (flags & AT_REMOVEDIR) {
-               ret = streams_depot_rmdir(handle, smb_fname);
+               ret = streams_depot_rmdir_internal(handle, smb_fname);
        } else {
                ret = streams_depot_unlink_internal(handle,
                                dirfsp,
@@ -831,6 +830,13 @@ static int streams_depot_unlinkat(vfs_handle_struct *handle,
        return ret;
 }
 
+static int streams_depot_rmdir(vfs_handle_struct *handle,
+                               const struct smb_filename *smb_fname)
+{
+       return streams_depot_rmdir_internal(handle,
+                               smb_fname);
+}
+
 static int streams_depot_renameat(vfs_handle_struct *handle,
                                files_struct *srcfsp,
                                const struct smb_filename *smb_fname_src,