From: Michael Adam Date: Wed, 29 May 2013 15:10:51 +0000 (+0200) Subject: shadow_copy2: introduce the bool "snapdir_absolute" in the config. X-Git-Url: http://git.samba.org/?a=commitdiff_plain;h=843954989cbec6640d2565d0d23a48f296740a23;p=metze%2Fsamba%2Fwip.git shadow_copy2: introduce the bool "snapdir_absolute" in the config. Not exposed but to be used internally. Signed-off-by: Michael Adam Reviewed-by: Andrew Bartlett --- diff --git a/source3/modules/vfs_shadow_copy2.c b/source3/modules/vfs_shadow_copy2.c index d5b16536c33e..069447358ccd 100644 --- a/source3/modules/vfs_shadow_copy2.c +++ b/source3/modules/vfs_shadow_copy2.c @@ -1646,6 +1646,16 @@ static int shadow_copy2_connect(struct vfs_handle_struct *handle, return -1; } + if (config->snapdir[0] == '/') { + config->snapdir_absolute = true; + if (config->snapdirseverywhere == true) { + DEBUG(1, (__location__ " Warning: An absolute snapdir " + "is incompatible with 'snapdirseverywhere', " + "setting 'snapdirseverywhere' to false.\n")); + config->snapdirseverywhere = false; + } + } + SMB_VFS_HANDLE_SET_DATA(handle, config, NULL, struct shadow_copy2_config, return -1);