diff options
-rw-r--r-- | win32/win32.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -4843,13 +4843,13 @@ rb_w32_read_reparse_point(const WCHAR *path, rb_w32_reparse_buffer_t *rp, } else { /* IO_REPARSE_TAG_MOUNT_POINT */ static const WCHAR *volume = L"Volume{"; - /* +4/-4 means to drop "\??\" */ name = ((char *)rp->MountPointReparseBuffer.PathBuffer + rp->MountPointReparseBuffer.SubstituteNameOffset + - 4 * sizeof(WCHAR)); ret = rp->MountPointReparseBuffer.SubstituteNameLength; *len = ret / sizeof(WCHAR); - ret -= 4 * sizeof(WCHAR); if (ret > sizeof(volume) - 1 * sizeof(WCHAR) && memcmp(name, volume, sizeof(volume) - 1 * sizeof(WCHAR)) == 0) return -1; |