Commit 6264ba4f authored by con's avatar con
Browse files

Make QString dumper fail faster in case of uninitialized variables


Reviewed-by: default avatarhjk <qtc-committer@nokia.com>
parent a8aa5c82
......@@ -2025,7 +2025,8 @@ static void qDumpQString(QDumper &d)
if (!str.isEmpty()) {
qCheckAccess(str.unicode());
qCheckAccess(str.unicode() + str.size());
if (!str.unicode()[str.size()].isNull()) // must be '\0' terminated
qCheckAccess(0);
}
P(d, "value", str);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment