From 83db71e9a71f01d6a9eea2d1436bd9ee28c250a0 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Sun, 18 Oct 2009 14:14:16 +1100 Subject: s4-pvfs: when reporting the file name, don't include the :$DATA suffix --- source4/ntvfs/posix/pvfs_resolve.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'source4') diff --git a/source4/ntvfs/posix/pvfs_resolve.c b/source4/ntvfs/posix/pvfs_resolve.c index 8c5806d93f..c01799e68c 100644 --- a/source4/ntvfs/posix/pvfs_resolve.c +++ b/source4/ntvfs/posix/pvfs_resolve.c @@ -263,6 +263,16 @@ static NTSTATUS pvfs_unix_path(struct pvfs_state *pvfs, const char *cifs_name, NTSTATUS status; name->original_name = talloc_strdup(name, cifs_name); + + /* remove any :$DATA */ + p = strrchr(name->original_name, ':'); + if (p && strcasecmp_m(p, ":$DATA") == 0) { + if (p > name->original_name && p[-1] == ':') { + p--; + } + *p = 0; + } + name->stream_name = NULL; name->stream_id = 0; name->has_wildcard = false; -- cgit