Callback deadlock

Stephan Bergmann sbergman at redhat.com
Mon Jun 29 05:18:27 PDT 2015


On 06/29/2015 10:53 AM, Matthew J. Francis wrote:
> It's remote - a test running as an external process.
>
> The Python side of the deadlock is http://pastebin.com/qPkyVTkk
> (this is a different run - the corresponding soffice.bin trace is
> http://pastebin.com/g4F8zcUi )
>
> The two things that seem to be happening are:
>
> In thread 1, the main Python thread has got the Text property for the
> text document being worked on, and PyUNO_new_UNCHECKED() is called to
> make a Python object for the result, which calls
> createInstanceWithArguments()
>
> Meanwhile, in thread 2, the windowActivated() callback bas been
> received, and pyuno::PyUNO_new_UNCHECKED() is called to make a Python
> object for the argument, which calls createInstanceWithArguments()
>
>
> If this sequence doesn't work, I'm not sure what if anything the Python
> side can do better here.

ah, that's a poorly implemented Implementation::inspect 
(stoc/source/inspect/introspection.cxx), which locks some m_aMutex first 
thing and for the duration of the whole function call, and both 
Pyhton-side threads 1 and 2 are in this function...


More information about the LibreOffice mailing list