Skip to content

Commit a9b806a

Browse files
authored
Merge pull request #8097 from FirebirdSQL/work/gh-8066
Implement #8066 : Make protocol schemes case-insensitive.
2 parents e96fc77 + 00f294f commit a9b806a

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/common/isc_file.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -405,7 +405,11 @@ bool ISC_analyze_protocol(const char* protocol, tstring& expanded_name, tstring&
405405
node_name.erase();
406406

407407
const PathName prefix = PathName(protocol) + "://";
408-
if (expanded_name.find(prefix) != 0)
408+
409+
if (prefix.length() > expanded_name.length())
410+
return false;
411+
412+
if (IgnoreCaseComparator::compare(prefix.c_str(), expanded_name.c_str(), prefix.length()) != 0)
409413
return false;
410414

411415
PathName savedName = expanded_name;

0 commit comments

Comments
 (0)