Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Unloading the QLibrary causes a crash on exit
Forum Updated to NodeBB v4.3 + New Features

Unloading the QLibrary causes a crash on exit

Scheduled Pinned Locked Moved Unsolved General and Desktop
dllcrashqapplication
9 Posts 2 Posters 3.3k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    Arus1
    wrote on last edited by Arus1
    #1

    In Qt (v5.2) Windows application several dlls are used, and some of them have .ui files. If the UI from dll is opened at least once, no matter if it is closed or still open, on quit the application crashes if the corresponding dll is unloaded (using unload() function).
    Is there a solution to avoid this issue?
    Thanks in advance.

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      Are these files stored using Qt's resources system ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • A Offline
        A Offline
        Arus1
        wrote on last edited by Arus1
        #3

        No, resource system is not used to store dll/ui files. The dll files are loaded using the full path.

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          I was thinking about the ui files

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • A Offline
            A Offline
            Arus1
            wrote on last edited by
            #5

            Ui files use resource system (to keep resources), but the Ui files themselves are not included in the resource system

            1 Reply Last reply
            0
            • A Offline
              A Offline
              Arus1
              wrote on last edited by
              #6

              I would like to mention that the same issue does not occur in Qt 4.8

              1 Reply Last reply
              0
              • SGaistS Offline
                SGaistS Offline
                SGaist
                Lifetime Qt Champion
                wrote on last edited by
                #7

                Then you might be experiencing a regression.

                You should take a look at the bug report system to see if it's something known. If not please consider opening a bug report providing a minimal compilable example that reproduces the behavior.

                Interested in AI ? www.idiap.ch
                Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                1 Reply Last reply
                0
                • A Offline
                  A Offline
                  Arus1
                  wrote on last edited by
                  #8

                  But I think there should be a workaround.
                  Also is it necessary to unload dlls explicitly (using unload() function)?

                  1 Reply Last reply
                  0
                  • SGaistS Offline
                    SGaistS Offline
                    SGaist
                    Lifetime Qt Champion
                    wrote on last edited by
                    #9

                    It's rarely needed to call unload.

                    Interested in AI ? www.idiap.ch
                    Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                    1 Reply Last reply
                    0

                    • Login

                    • Login or register to search.
                    • First post
                      Last post
                    0
                    • Categories
                    • Recent
                    • Tags
                    • Popular
                    • Users
                    • Groups
                    • Search
                    • Get Qt Extensions
                    • Unsolved