|
@@ -197,7 +197,7 @@ wchar_t *wstrstri(const wchar_t *str, const wchar_t *find)
|
|
|
return NULL;
|
|
|
}
|
|
|
|
|
|
-static inline bool is_padding(char ch)
|
|
|
+static inline bool is_padding(int ch)
|
|
|
{
|
|
|
return ch == ' ' || ch == '\t' || ch == '\n' || ch == '\r';
|
|
|
}
|
|
@@ -244,7 +244,7 @@ wchar_t *wcsdepad(wchar_t *str)
|
|
|
temp = str;
|
|
|
|
|
|
/* remove preceding spaces/tabs */
|
|
|
- while (*temp == ' ' || *temp == '\t')
|
|
|
+ while (is_padding(*temp))
|
|
|
++temp;
|
|
|
|
|
|
len = wcslen(temp);
|
|
@@ -253,7 +253,7 @@ wchar_t *wcsdepad(wchar_t *str)
|
|
|
|
|
|
if (len) {
|
|
|
temp = str + (len - 1);
|
|
|
- while (*temp == ' ' || *temp == '\t')
|
|
|
+ while (is_padding(*temp))
|
|
|
*(temp--) = 0;
|
|
|
}
|
|
|
|