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. Proper thread termination confirmation?
Forum Update on Monday, May 27th 2025

Proper thread termination confirmation?

Scheduled Pinned Locked Moved Unsolved General and Desktop
multithreadingqthread
1 Posts 1 Posters 281 Views
  • 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.
  • C Offline
    C Offline
    CJha
    wrote on 12 Aug 2022, 11:49 last edited by
    #1

    Hi, I have a few threads which are always active, I have overridden their void run() function to execute my code when required. I also have added a qDebug() message in the threads destructor to observe when it is destroyed, this message is never printed when I am closing the application. There are no error messages as well. I got the thread ID using the Qt::HANDLE QThread::currentThreadId() and when the application is closed I can see the message ex. The thread 0x43f4 has exited with code 0 (0x0). where the ID (0x43f4) is my thread. Is this message enough to assume that the threads are getting destroyed properly? If so, why my debug message from the destructor is not getting printed?

    1 Reply Last reply
    0

    1/1

    12 Aug 2022, 11:49

    • Login

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