Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-60728

QJsonObject repetitive read/write of a key (large) results in error

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • None
    • 5.8.0
    • None
    • Windows 7 x64, 

      Qt 5.8.0 MSVC2013 32 bit

    Description

      Repetitive read/write of the same key to a QJsonObject results in the error:

      QJson: Document too large to store in data structure

       

       

      How to reproduce:

      I have a large QJsonObject (size of ~40 Mb when saved to a json file).

      I call this procedure from the GUI:

       

      {
        QJsonObject jRC = obj->js["a1"].toObject();
        obj->js["a1"] = jRC;
      }
      

       

      Note that "a1" holds most of the content of object.
      First ~ten calls are successful, the object is fine.

      the next call results in the error:
      QJson: Document too large to store in data structure

      Write is not performed

       

      Using "take" to remove the "a1" key from obj before writing it back results in the same behavior.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              laknoll Lars Knoll
              andreymor Andrey
              Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes