diff options
| -rw-r--r-- | CHANGES | 2 | ||||
| -rw-r--r-- | src/filename_absolute.cxx | 4 |
2 files changed, 4 insertions, 2 deletions
@@ -2,6 +2,8 @@ CHANGES IN FLTK 1.1.7 - Documentation fixes (STR #648, STR #692, STR #730, STR #744, STR #745) + - fl_filename_relative() didn't compare drive letters in + a case-insensitive way (STR #741) - Fixed menu item width calculations with symbols (STR #740) - The keyboard shortcut handling code did not handle diff --git a/src/filename_absolute.cxx b/src/filename_absolute.cxx index 9a65ddb0a..bec93c1d3 100644 --- a/src/filename_absolute.cxx +++ b/src/filename_absolute.cxx @@ -137,7 +137,7 @@ fl_filename_relative(char *to, // O - Relative filename return (1); } - if (*from != *cwd) { + if (tolower(*from & 255) != tolower(*cwd & 255)) { // Not the same drive... strlcpy(to, from, tolen); return 0; @@ -155,7 +155,7 @@ fl_filename_relative(char *to, // O - Relative filename slash ++, newslash ++) if (isdirsep(*slash) && isdirsep(*newslash)) continue; #if defined(WIN32) || defined(__EMX__) || defined(__APPLE__) - else if (tolower(*slash) != tolower(*newslash)) break; + else if (tolower(*slash & 255) != tolower(*newslash & 255)) break; #else else if (*slash != *newslash) break; #endif // WIN32 || __EMX__ || __APPLE__ |
