Skip to content

Commit

Permalink
ntfs::ntfs: work with lowercase drive letters
Browse files Browse the repository at this point in the history
  • Loading branch information
maharmstone committed Sep 24, 2021
1 parent 2501307 commit 209d28b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ntfs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ ntfs::ntfs(const string& fn) {
wstring_convert<codecvt_utf8_utf16<char16_t>, char16_t> convert;
u16string namew;

if ((fn.length() == 2 || fn.length() == 3) && fn[0] >= 'A' && fn[0] <= 'Z' && fn[1] == ':' && (fn.length() == 2 || fn[2] == '\\')) {
if ((fn.length() == 2 || fn.length() == 3) && ((fn[0] >= 'A' && fn[0] <= 'Z') || (fn[0] >= 'a' && fn[0] <= 'z')) && fn[1] == ':' && (fn.length() == 2 || fn[2] == '\\')) {
namew = u"\\\\.\\X:";
namew[4] = fn[0];
drive = true;
Expand Down

0 comments on commit 209d28b

Please sign in to comment.