[Interest] Best way to terminate threads using QWaitCondition

Thiago Macieira thiago.macieira at intel.com
Sat Nov 21 21:26:26 CET 2015


On Saturday 21 November 2015 13:12:03 Bob Hood wrote:
> I wanted some advice from the brain trust on the best means of terminating
> threads 

Just to be clear: you need to exit cleanly. Do not ever use the terminate() 
call.

You're not doing that. I just wanted to get this out front before anyone 
suggests this.

> that are synchronizing using QMutex/QWaitCondition.  In my working
> code, I'm getting error messages that look like:
> 
>      QWaitCondition: cv destroy failure: Device or resource busy
>      QWaitCondition: mutex destroy failure: Device or resource busy

What's the backtrace of those warnings? Which thread were they printed from?

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center




More information about the Interest mailing list