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. Segmentation fault when exiting when linked against Qt 6.9.1
Forum Updated to NodeBB v4.3 + New Features

Segmentation fault when exiting when linked against Qt 6.9.1

Scheduled Pinned Locked Moved Solved General and Desktop
35 Posts 7 Posters 3.2k Views 3 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
    Axel Spoerl
    Moderators
    wrote on 17 Jun 2025, 12:32 last edited by Axel Spoerl
    #21

    Great reproducer!
    Someone decades ago felt like storing unused tab bars for later re-usage in QMainWindowLayout.
    Those were soft-leaked and taken care off, when QApplication got destroyed.
    Reading the state back from settings causes the original tab bar (created in the C++ part) to become unused, but not removed from its QMainWindow parent. That ultimately lead to a double delete and the crash.
    Let's see, if my thorough reviewers let me get away without writing an autotest ;-)

    Software Engineer
    The Qt Company, Oslo

    1 Reply Last reply
    3
    • L Offline
      L Offline
      l3u_
      wrote on 18 Jun 2025, 08:35 last edited by
      #22

      Wow, that was fast :-) Thanks for the immediate fix! Nice to see my stuff helped here!

      That was quite deep inside Qt apparently … where will this land? Qt 6.10.0? Or will it be backported?

      I tried to cherry-pick it to a 6.9.1 checkout to test it, but it seems that's no trivial task …

      J 1 Reply Last reply 18 Jun 2025, 08:50
      0
      • L l3u_
        18 Jun 2025, 08:35

        Wow, that was fast :-) Thanks for the immediate fix! Nice to see my stuff helped here!

        That was quite deep inside Qt apparently … where will this land? Qt 6.10.0? Or will it be backported?

        I tried to cherry-pick it to a 6.9.1 checkout to test it, but it seems that's no trivial task …

        J Offline
        J Offline
        jsulm
        Lifetime Qt Champion
        wrote on 18 Jun 2025, 08:50 last edited by
        #23

        @l3u_ You can see in the bug report:
        Fix Version/s: 6.10.0 Beta2, 6.11.0 FF

        https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply
        0
        • L Offline
          L Offline
          l3u_
          wrote on 18 Jun 2025, 13:01 last edited by l3u_
          #24

          Ah okay. So no 6.9 backport? I just wondered, because in the respective "Change ID" https://codereview.qt-project.org/c/qt/qtbase/+/653727, it's listed: "Fixes: QTBUG-137755 Pick-to: 6.10 6.9"

          J 1 Reply Last reply 18 Jun 2025, 13:09
          0
          • L l3u_
            18 Jun 2025, 13:01

            Ah okay. So no 6.9 backport? I just wondered, because in the respective "Change ID" https://codereview.qt-project.org/c/qt/qtbase/+/653727, it's listed: "Fixes: QTBUG-137755 Pick-to: 6.10 6.9"

            J Offline
            J Offline
            jsulm
            Lifetime Qt Champion
            wrote on 18 Jun 2025, 13:09 last edited by
            #25

            @l3u_ Yes, it looks like it was cherry picked to 6.9 branch, so may end up in some 6.9.x version :-)

            https://forum.qt.io/topic/113070/qt-code-of-conduct

            1 Reply Last reply
            0
            • A Offline
              A Offline
              Axel Spoerl
              Moderators
              wrote on 18 Jun 2025, 16:12 last edited by
              #26

              The fix will land in 6.9.2, which we plan to release on August 14th.

              If you want to cherry pick and compile locally, please make sure to pick the following 5 commits in the right order:

              1. https://codereview.qt-project.org/c/qt/qtbase/+/653890
              2. https://codereview.qt-project.org/c/qt/qtbase/+/653891
              3. https://codereview.qt-project.org/c/qt/qtbase/+/653892
              4. https://codereview.qt-project.org/c/qt/qtbase/+/653893
              5. https://codereview.qt-project.org/c/qt/qtbase/+/653894

              Software Engineer
              The Qt Company, Oslo

              1 Reply Last reply
              3
              • L Offline
                L Offline
                l3u_
                wrote on 18 Jun 2025, 18:16 last edited by
                #27

                Nice :-)

                I just tried it locally, cherry-picking the exact comments you linked. Worked without a collision on a v6.9.1 checkout.

                And – you may already have thought that – I can confirm the segfault is gone now, also for my quite complex use-case :-)

                1 Reply Last reply
                3
                • A Offline
                  A Offline
                  Axel Spoerl
                  Moderators
                  wrote on 18 Jun 2025, 19:42 last edited by
                  #28

                  Great that you are using dock widgets! As you may have suspected: QDockWidget is slightly closer to my heart than other creatures in the widget zoo ;-)

                  Software Engineer
                  The Qt Company, Oslo

                  S 1 Reply Last reply 26 Jun 2025, 10:03
                  1
                  • L Offline
                    L Offline
                    l3u_
                    wrote on 19 Jun 2025, 06:01 last edited by
                    #29

                    First, it was just a QTabBar interface. But over the years, it got more and more complex, and at some point, I learned about QDockWidgets – and I loved them at first sight ;-) The same as the tab bar if you want – but way more if you need it. The possibility to arrange them as you like and need is really nice. This is actually a powerful tool, with a great user experience. QDockWidgets really rock! They do, from time to time, cause some headache (this is actually not the first bug I filed about them ;-) – but they are really cool.

                    1 Reply Last reply
                    2
                    • A Offline
                      A Offline
                      Axel Spoerl
                      Moderators
                      wrote on 21 Jun 2025, 20:37 last edited by
                      #30

                      @l3u_
                      Could you mark this thread as solved, please?

                      Software Engineer
                      The Qt Company, Oslo

                      1 Reply Last reply
                      0
                      • A Axel Spoerl
                        18 Jun 2025, 19:42

                        Great that you are using dock widgets! As you may have suspected: QDockWidget is slightly closer to my heart than other creatures in the widget zoo ;-)

                        S Offline
                        S Offline
                        StudentScripter
                        wrote on 26 Jun 2025, 10:03 last edited by
                        #31

                        @Axel-Spoerl Love QDockwidget too, great work <3

                        I always miss them in QML ( i know that QML is mainly mobile focused but nevertheless). :D

                        1 Reply Last reply
                        1
                        • A Offline
                          A Offline
                          Axel Spoerl
                          Moderators
                          wrote on 26 Jun 2025, 10:15 last edited by
                          #32

                          @StudentScripter Not as an immediate priority, but we are planning to implement something like dock widgets also in Quick Controls.

                          Software Engineer
                          The Qt Company, Oslo

                          S 1 Reply Last reply 15 days ago
                          1
                          • L l3u_ has marked this topic as solved 29 days ago
                          • A Axel Spoerl
                            26 Jun 2025, 10:15

                            @StudentScripter Not as an immediate priority, but we are planning to implement something like dock widgets also in Quick Controls.

                            S Offline
                            S Offline
                            StudentScripter
                            wrote 15 days ago last edited by
                            #33

                            @Axel-Spoerl Awesome <3 Is it on the near roadmap or will have to wait a few years?

                            JonBJ 1 Reply Last reply 15 days ago
                            0
                            • S StudentScripter
                              15 days ago

                              @Axel-Spoerl Awesome <3 Is it on the near roadmap or will have to wait a few years?

                              JonBJ Offline
                              JonBJ Offline
                              JonB
                              wrote 15 days ago last edited by JonB 7 Nov 2025, 08:21
                              #34

                              @StudentScripter Just so you know, @Axel-Spoerl is away atm and won't answer for a week or two...

                              S 1 Reply Last reply 15 days ago
                              1
                              • JonBJ JonB
                                15 days ago

                                @StudentScripter Just so you know, @Axel-Spoerl is away atm and won't answer for a week or two...

                                S Offline
                                S Offline
                                StudentScripter
                                wrote 15 days ago last edited by
                                #35

                                @JonB Thanks for the hint, but im in no hurry right now. :D Have a nice day.

                                1 Reply Last reply
                                0

                                21/35

                                17 Jun 2025, 12:32

                                • Login

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