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

WebAssembly QSettings crash using clear()

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P1: Critical
    • None
    • 6.4.2
    • Core: Other
    • None
    • Chrome / firefox
    • WebAssembly

    Description

      Using QSettings in c++ with the linked code,

       

      When clicking the switch-me switch, we save the new state.
      Note also that we save a empty and not useful array.

       

      When clicking the clear button, we will issue a call to QSettings.clear(). This call will result in a javascript error in the browser.

       

      Using a production app, the application completly crash and we are back to the Qt loader screen with the same issue: "Cannot pass non-string to std::string".

      Note that the issue does not happen if you do not create the array in the settings.

      Attachments

        1. Screenshot_20230206_111244.png
          Screenshot_20230206_111244.png
          316 kB
        2. main.qml
          0.5 kB
        3. main.cpp
          0.6 kB
        4. Controller-1.cpp
          0.5 kB
        5. Controller.h
          0.5 kB
        6. CMakeLists.txt
          0.8 kB

        Activity

          People

            lpotter Lorn Potter
            qdel Deldycke Quentin
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: