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

Multiple events emitted from a single object in different thread cause NullPointer exception in QStateMachinePrivate

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: P2: Important P2: Important
    • 5.9.4
    • 5.8.0
    • State Machine
    • None
    • Linux Ubuntu 16.04, MacOS El Capitan.
    • 345be581007c05164052e27f90fcfaf27a41c743

      A simple scenario.

       

      State machine s1->final_State

      With transition from an object that lives in a different thread.

      If the objects emits a signal multiple times, the first one is consumed correctly. The second one causes core dump since sender is NULL in QStateMachinePrivate::handleTransitionSignal.

       

      MWE project is in attachment. Just click on the button.

        1. workerth.h
          0.4 kB
        2. workerth.cpp
          0.4 kB
        3. win.h
          0.3 kB
        4. win.cpp
          0.5 kB
        5. pp.pro
          0.4 kB
        6. main.cpp
          3 kB
        7. emitter.h
          0.2 kB
        8. emitter.cpp
          0.1 kB
        For Gerrit Dashboard: QTBUG-61463
        # Subject Branch Project Status CR V

            jefernan Jesus Fernandez
            pavleb Pavle Boskoski
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes