summaryrefslogtreecommitdiffstats
path: root/src/corelib/json/qjsondocument.h
diff options
context:
space:
mode:
authorAlexei Rousskikh <ext-alexei.rousskikh@nokia.com>2012-03-12 14:33:39 -0400
committerQt by Nokia <qt-info@nokia.com>2012-03-12 21:38:51 +0100
commit612040a0cd702e4c764e5cbb5d0c091497650c6a (patch)
treea47186f97ae77e71495c4e6b3765a2d9d5236491 /src/corelib/json/qjsondocument.h
parent0353430806fb14b438cf7d68c68d8cdbcb57ef45 (diff)
Trailing comma should result in an error during JSON parsing
1. QJsonParseError::MissingObject defined 2. QJsonDocument::fromJson() will result in defined error after parsing of something like "{ 'key':1 , }" or "[ {'key':1}, ]" Change-Id: I8e6234a03b8aca4e5ad6180f273f91066b86d7a1 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Diffstat (limited to 'src/corelib/json/qjsondocument.h')
-rw-r--r--src/corelib/json/qjsondocument.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/corelib/json/qjsondocument.h b/src/corelib/json/qjsondocument.h
index 7eca0302db..e39dc6a27c 100644
--- a/src/corelib/json/qjsondocument.h
+++ b/src/corelib/json/qjsondocument.h
@@ -67,7 +67,8 @@ struct Q_CORE_EXPORT QJsonParseError
IllegalNumber,
StringEscapeSequence,
StringUTF8Scan,
- EndOfString
+ EndOfString,
+ MissingObject
};
int offset;