summaryrefslogtreecommitdiff
path: root/src/shared/logs-show.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/shared/logs-show.c')
-rw-r--r--src/shared/logs-show.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/shared/logs-show.c b/src/shared/logs-show.c
index b78cb7678c..60144ab8a6 100644
--- a/src/shared/logs-show.c
+++ b/src/shared/logs-show.c
@@ -575,7 +575,6 @@ void json_escape(
assert(p);
if (!(flags & OUTPUT_SHOW_ALL) && l >= JSON_THRESHOLD)
-
fputs("null", f);
else if (!utf8_is_printable(p, l)) {
@@ -605,8 +604,8 @@ void json_escape(
fputc(*p, f);
} else if (*p == '\n')
fputs("\\n", f);
- else if (*p < ' ')
- fprintf(f, "\\u%04x", *p);
+ else if ((uint8_t) *p < ' ')
+ fprintf(f, "\\u%04x", (uint8_t) *p);
else
fputc(*p, f);