X-Git-Url: https://repo.jachan.dev/qemu.git/blobdiff_plain/c96c84a9ff4bc184cb1f6cc9771a550f3854ba59..19e83f6bdf86f92ee90db77d606affe5b08f8b40:/json-parser.c diff --git a/json-parser.c b/json-parser.c index b55d76373e..6c06ef91a6 100644 --- a/json-parser.c +++ b/json-parser.c @@ -11,7 +11,6 @@ * */ -#include #include #include "qemu-common.h" @@ -92,7 +91,8 @@ static int token_is_escape(QObject *obj, const char *value) /** * Error handler */ -static void parse_error(JSONParserContext *ctxt, QObject *token, const char *msg, ...) +static void GCC_FMT_ATTR(3, 4) parse_error(JSONParserContext *ctxt, + QObject *token, const char *msg, ...) { va_list ap; va_start(ap, msg); @@ -206,6 +206,10 @@ static QString *qstring_from_escaped_str(JSONParserContext *ctxt, QObject *token qstring_append(str, "\b"); ptr++; break; + case 'f': + qstring_append(str, "\f"); + ptr++; + break; case 'n': qstring_append(str, "\n"); ptr++;