mirror of
https://github.com/lunarmodules/luafilesystem.git
synced 2026-07-22 02:53:06 +00:00
win32: strip UNC prefix if present
This commit is contained in:
@@ -953,6 +953,12 @@ static int push_link_target(lua_State *L) {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (tsize < size) {
|
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;
|
ok = 1;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user