This fixes viewing the content of snapshots in the share root directory. We
have to treat the filename that *just* consists of "@GMT-YYYY.MM.DD-HH.MM.SS"
like the share root, which is the current working directory.
static char *shadow_copy2_realpath(vfs_handle_struct *handle,
const char *fname, char *resolved_path)
{
+ if (shadow_copy2_match_name(fname) && (fname[GMT_NAME_LEN] == '\0')) {
+ return SMB_VFS_NEXT_REALPATH(handle, ".", resolved_path);
+ }
SHADOW2_NEXT(REALPATH, (handle, name, resolved_path), char *, NULL);
}