Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitaa38153

Browse files
committed
Make directory name comparisons on Win32 case insensitive.
This method will not catch all different ways since the localehandling in NTFS doesn't provide an easy way to do that, but itwill hopefully solve the most common cases causing startupproblems when the backend is found in the system PATH.Attempts to fix bug #4694.
1 parentd0b5990 commitaa38153

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

‎src/port/path.c

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/port/path.c,v 1.76 2009/01/01 17:24:04 momjian Exp $
11+
* $PostgreSQL: pgsql/src/port/path.c,v 1.77 2009/04/03 11:52:08 mha Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -427,7 +427,12 @@ dir_strcmp(const char *s1, const char *s2)
427427
{
428428
while (*s1&&*s2)
429429
{
430+
#ifndefWIN32
430431
if (*s1!=*s2&&
432+
#else
433+
/* On windows, paths are case-insensitive */
434+
if (pg_tolower(*s1)!=pg_tolower(*s2)&&
435+
#endif
431436
!(IS_DIR_SEP(*s1)&&IS_DIR_SEP(*s2)))
432437
return (int)*s1- (int)*s2;
433438
s1++,s2++;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp