mirror of
https://github.com/ventoy/Ventoy.git
synced 2025-08-28 00:11:15 +00:00
Fix the drive letter case check issue for VentoyPlugson in Windows. (#2078)
This commit is contained in:
@@ -33,6 +33,8 @@ function ventoy_get_ulen(str) {
|
||||
|
||||
|
||||
function ventoy_common_check_path(path) {
|
||||
var curdir
|
||||
|
||||
if (path.indexOf('//') >= 0) {
|
||||
return false;
|
||||
}
|
||||
@@ -41,7 +43,12 @@ function ventoy_common_check_path(path) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (path.substr(0, g_current_dir.length) != g_current_dir) {
|
||||
curdir = path.substr(0, g_current_dir.length);
|
||||
if (curdir.match("^[a-z]:$")) {
|
||||
curdir = curdir.toUpperCase();
|
||||
}
|
||||
|
||||
if (curdir != g_current_dir) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user