diff options
author | Hisham Muhammad <hisham@gobolinux.org> | 2020-04-21 07:15:12 +0300 |
---|---|---|
committer | Hisham Muhammad <hisham@gobolinux.org> | 2020-04-21 19:45:50 +0300 |
commit | 1a61e5284df50cdccd065424dfcb1975dace4c2d (patch) | |
tree | ed2d72002489b28a37b58d27ca3577b22021cfdb | |
parent | 7cb7d86dc4ae9b7305c46277cc26ae4d9c645588 (diff) |
win32: strip UNC prefix if present
-rw-r--r-- | src/lfs.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -953,6 +953,12 @@ static int push_link_target(lua_State *L) { break; } if (tsize < size) { +#ifdef _WIN32 + if (tsize > 4 && strncmp(target, "\\\\?\\", 4) == 0) { + memmove_s(target, tsize - 3, target + 4, tsize - 3); + tsize -= 4; + } +#endif ok = 1; break; } |