Re: GTK deadlock in gtk_main



Hi,

So what you suggest is to have gdk_threads_enter and gdk_threads_leave at
the beginning and at the end of the idle function?

Is this really intended?

Anyway, thanks for your help.

Regards,
Tomas

Hi.

You're having troubles because gtk_main_iteration_do() does it's own
unlock/lock cycle.

When your idle callback is executed, your mutex is unlocked.
gtk_main_iteration_do() "unlocks" it again, executes whatever is there
to be executed and locks it. Now control returns back to main loop,
which tries to lock mutex and here you have your lock.

Tadej

--
Tadej Borovšak
tadeboro.blogspot.com
tadeboro gmail com
tadej borovsak gmail com






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]