Skip to content

Commit 75b360a

Browse files
authored
spot fix open-source-parsers#1171: isprint argument must be representable as unsigned char (open-source-parsers#1173)
1 parent e36cff1 commit 75b360a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib_json/json_writer.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ String valueToString(bool value) { return value ? "true" : "false"; }
178178
static bool isAnyCharRequiredQuoting(char const* s, size_t n) {
179179
assert(s || !n);
180180

181-
return std::any_of(s, s + n, [](int c) {
181+
return std::any_of(s, s + n, [](unsigned char c) {
182182
return c == '\\' || c == '"' || !std::isprint(c);
183183
});
184184
}

0 commit comments

Comments
 (0)