vfs_shadow_copy2: add shadow_copy2_do_convert()
authorUri Simchoni <uri@samba.org>
Sun, 1 Nov 2015 20:28:46 +0000 (22:28 +0200)
committerMichael Adam <obnox@samba.org>
Wed, 13 Jan 2016 13:03:15 +0000 (14:03 +0100)
commit3703bca4d9e494aec0b40243add3e076cf353601
treea6d16caa50d59992c0c1918dbe3dca8af21d6c4d
parentfba90fd8fe5e3082a67db52b351c2d3ed2d05268
vfs_shadow_copy2: add shadow_copy2_do_convert()

Add a new routine shadow_copy2_do_convert() which is
like shadow_copy2_convert(), but beside calculating the
path of the snapshot file, it also returns the minimum length
of the subpath which is both inside the share and inside the
same snapshot as the file in question, i.e. (at least in the
classical case) the subdirectory of the the snapshot file's
snapshot directory that corresponds to the file's share root.

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

Signed-off-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
source3/modules/vfs_shadow_copy2.c