Util/CharUtil: new library replacing g_ascii_isX()

This commit is contained in:
Max Kellermann
2013-10-19 15:25:32 +02:00
parent 90777f78c9
commit b39ab76118
8 changed files with 134 additions and 17 deletions

View File

@@ -20,12 +20,11 @@
#include "config.h"
#include "TextInputStream.hxx"
#include "InputStream.hxx"
#include "util/CharUtil.hxx"
#include "util/fifo_buffer.h"
#include "util/Error.hxx"
#include "Log.hxx"
#include <glib.h>
#include <assert.h>
#include <string.h>
@@ -71,7 +70,7 @@ bool TextInputStream::ReadLine(std::string &line)
} while (p == nullptr);
size_t length = p - src + 1;
while (p > src && g_ascii_isspace(p[-1]))
while (p > src && IsWhitespaceOrNull(p[-1]))
--p;
line = std::string(src, p - src);