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

REG->dev: Application hangs when calling close on hidden window via timer

    XMLWordPrintable

Details

    • Bug
    • Resolution: Invalid
    • P1: Critical
    • None
    • 6.3
    • GUI: Window management
    • None
    • All

    Description

      I am not sure if this is a real bug or intended change of behaviour, but at f2de001d8410b85047ee40ebfff1b307a18889bb , the code

          QApplication a(argc, argv);
          QWidget w;
         //    w.show();
          QTimer::singleShot(0, &w, &QWidget::close);
          return  a.exec();
      

      hangs. Note the widget is not shown. The app terminates normally when calling show().

      The attached sample produces

      Qt 6.3.0 (x86_64-little_endian-lp64 shared (dynamic) debug build; by GCC 9.3.0)
      Timer running
      

      vs

      Qt 6.2.0 (x86_64-little_endian-lp64 shared (dynamic) debug build; by GCC 9.3.0)
      Timer running
      Exit 0
      

      Manifested in a Qt for Python test

      Attachments

        1. qtbug97033.zip
          0.8 kB
          Friedemann Kleint
        For Gerrit Dashboard: QTBUG-97033
        # Subject Branch Project Status CR V

        Activity

          People

            vestbo Tor Arne Vestbø
            kleint Friedemann Kleint
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes