Use g_ascii_isspace instead of isspace because the later is slower and we

only need to deal with ascii.
This commit is contained in:
Benoît Dejean
2017-01-22 10:45:26 +01:00
parent 7afc81f99d
commit 01a56e2e30
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -51,7 +51,7 @@ char *
skip_token (const char *p)
{
p = next_token(p);
while (*p && !isspace(*p)) p++;
while (*p && !g_ascii_isspace(*p)) p++;
p = next_token(p);
return (char *)p;
}
+1 -1
View File
@@ -37,7 +37,7 @@ G_BEGIN_DECLS
static inline char*
next_token(const char *p)
{
while (isspace(*p)) p++;
while (g_ascii_isspace(*p)) p++;
return (char*) p;
}