Details
-
Bug
-
Resolution: Cannot Reproduce
-
Not Evaluated
-
None
-
5.15.2
-
None
Description
If you want to compare a default constructed QJsonDocument to one that contains a QJsonObject, it will crash.
QJsonDocument doc1; QJsonDocument doc2; const bool iseq1 = doc1 == doc2; // no crash here QJsonObject obj; doc1.setObject(obj); const bool iseq2 = doc1 == doc2; // here it crashes
If we are comparing them the other way, it is working fine.
I suspect that in operator==, only this is checked for null, but the right-side argument is not.