]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3: VFS: shadow_copy2: Ensure pathnames for parameters are correctly relative and...
authorJeremy Allison <jra@samba.org>
Fri, 20 Jan 2017 19:45:54 +0000 (11:45 -0800)
committerKarolin Seeger <kseeger@samba.org>
Wed, 15 Feb 2017 10:42:22 +0000 (11:42 +0100)
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12531

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Uri Simchoni <uri@samba.org>
(backported from commit 979e39252bcc88e8aacb543b8bf322dd6f17fe7f)

source3/modules/vfs_shadow_copy2.c

index bbfad85b978a1b7b7eda2257d76988e445536a76..5f2e812c0a785bddcb0594b0b9c537ad270eb1df 100644 (file)
@@ -2161,6 +2161,11 @@ static int shadow_copy2_connect(struct vfs_handle_struct *handle,
                }
        }
 
+       trim_string(config->mount_point, NULL, "/");
+       trim_string(config->rel_connectpath, "/", "/");
+       trim_string(config->snapdir, NULL, "/");
+       trim_string(config->snapshot_basepath, NULL, "/");
+
        DEBUG(10, ("shadow_copy2_connect: configuration:\n"
                   "  share root: '%s'\n"
                   "  mountpoint: '%s'\n"