Ticket #414: wcscasecmpOSX-2.patch
File wcscasecmpOSX-2.patch, 646 bytes (added by , 14 years ago) |
---|
-
posix.h
96 96 97 97 #if OS_MACOSX 98 98 # define EMULATE_WCSDUP 1 99 100 #include <wctype.h> 101 #include <wchar.h> 102 103 inline int wcscasecmp (const wchar_t* s1, const wchar_t* s2) { 104 wint_t a1, a2; 105 106 if (s1 == s2) 107 return 0; 108 109 do 110 { 111 a1 = towlower(*s1++); 112 a2 = towlower(*s2++); 113 if (a1 == L'\0') 114 break; 115 } 116 while (a1 == a2); 117 118 return a1 - a2; 119 } 99 120 #else 100 121 # define EMULATE_WCSDUP 0 101 122 #endif … … 153 174 #endif // HAVE_C99_MATH 154 175 155 176 #endif // #ifndef INCLUDED_POSIX 177