Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.12
-
None
-
e114fec62a (qt/qtbase/dev) e114fec62a (qt/tqtc-qtbase/dev) 8b8cb92674 (qt/tqtc-qtbase/6.2) f7eada3203 (qt/qtbase/6.3) f3abda4836 (qt/qtbase/6.4) f7eada3203 (qt/tqtc-qtbase/6.3) f3abda4836 (qt/tqtc-qtbase/6.4) 8b8cb92674 (qt/tqtc-qtbase/6.2.5)
Description
The added check in commit 35adb74ddd915831789f0175423660f8e898942e
"n >= 0" seems to be incorrect.
small example:
const auto obj = QJsonObject{ { "key", QJsonArray() } }; const auto x = obj.value( "key" ).toArray( QJsonArray{ "default" } );
x should have the value QJsonArray() , but it will have the value QJsonArray{ "default" }