[PyQt] "Cannot unlock an unlocked lock"
Phil Thompson
phil at riverbankcomputing.com
Tue Jul 1 21:56:05 BST 2008
On Tue, 1 Jul 2008 21:25:55 +0200, "Matthieu Brucher"
<matthieu.brucher at gmail.com> wrote:
> Hello,
>
> I'm trying to use a lock on a thread, and I use the following code :
>
> try:
> self.lock.lockForWrite()
> self.currentScreen = 1 if self.currentScreen == 0 else 0
> finally:
> self.lock.unlock()
>
> The problem is that the finally close crashes with the following
> assertion error:
>
> ASSERT failure in QReadWriteLock::unlock(): "Cannot unlock an unlocked
> lock", file thread/qreadwritelock.cpp, line 346
>
> This is with Ubuntu, PyQt 4.4.3-2.
> With Fedora 8, PyQt 4.3.3, the assertion does not failed.
>
> Any idea ?
Not without a complete example that demonstrates the problem.
Phil
More information about the PyQt
mailing list