From: Eric Biggers Date: Tue, 21 May 2013 00:43:03 +0000 (-0500) Subject: path_is_root_of_drive(): Recognize \\?\-prefixed paths as being drive root X-Git-Tag: v1.4.1~72 X-Git-Url: https://wimlib.net/git/?p=wimlib;a=commitdiff_plain;h=b81519a7676f43fc26b2287b2d033711c22e4e99 path_is_root_of_drive(): Recognize \\?\-prefixed paths as being drive root --- diff --git a/src/win32_apply.c b/src/win32_apply.c index 7b7ff27b..11104f24 100644 --- a/src/win32_apply.c +++ b/src/win32_apply.c @@ -482,9 +482,12 @@ do_win32_extract_encrypted_stream(const wchar_t *path, static bool path_is_root_of_drive(const wchar_t *path) { - if (!*path) + if (*path == L'\0') return false; + if (!wcsncmp(path, L"\\\\?\\", 4)) + path += 4; + if (*path != L'/' && *path != L'\\') { if (*(path + 1) == L':') path += 2;