diff options
Diffstat (limited to 'TSRM/tsrm_virtual_cwd.c')
-rw-r--r-- | TSRM/tsrm_virtual_cwd.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/TSRM/tsrm_virtual_cwd.c b/TSRM/tsrm_virtual_cwd.c index ed4e5a3d71..66949fabcc 100644 --- a/TSRM/tsrm_virtual_cwd.c +++ b/TSRM/tsrm_virtual_cwd.c @@ -714,7 +714,9 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i tmp = tsrm_do_alloca(len+1, use_heap); memcpy(tmp, path, len+1); - if(save && (data.dwFileAttributes & FILE_ATTRIBUTE_REPARSE_POINT)) { + if(save && + !(IS_UNC_PATH(path, len) && len >= 3 && path[2] != '?') && + (data.dwFileAttributes & FILE_ATTRIBUTE_REPARSE_POINT)) { /* File is a reparse point. Get the target */ HANDLE hLink = NULL; REPARSE_DATA_BUFFER * pbuffer; |