[Kwintv] Re: V4L Plugin - new success

Dirk Ziegelmeier dirk at ziegelmeier.net
Sun Dec 14 23:18:30 CET 2003


On Sunday 14 December 2003 20:33, Koos Vriezen wrote:
> Well, I have a better fix (although I consider it a dirty hack). Problem is
> solved by temporary unlocking qApp and then wait for the grabber thread. It
> will exit on the second test for the _stopSem after retrieving the lock.
> However if another thread does a qApp->lock() it can fail miserably :-(,
> but that isn't done anyware afaics (but might be a time bomb of course).
Could we use QThread::terminate()? Yes, it's not very clean, but we now the 
grabber thread is not holding the qApp lock since we are in the event loop, 
and we don't care about the thread holding the devMutex since we won't be 
using it any more. To be sure, we could also acquire the devMutex before 
killing the thread. Find attached a patch for it. What do you think, Koos?

Ciao,
Dirk

--
Dirk Ziegelmeier * dirk at ziegelmeier.net * http://www.ziegelmeier.net
-------------- next part --------------
A non-text attachment was scrubbed...
Name: qtvision_v4l.patch
Type: text/x-diff
Size: 1218 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/kwintv/attachments/20031214/049d6a20/qtvision_v4l.bin


More information about the kwintv mailing list