[Gtk-sharp-list] Stalls when calling Gdk.Threads.Enter twice

Mads LindstrÝm mads_lindstroem@yahoo.dk
Mon, 12 Jul 2004 15:22:53 +0200 (CEST)


I wondered if the following was correct behavior or a
bug. I compiled the following program:

//compiled with mcs -L
/usr/share/dotnet/mono/gtk-sharp/ -r gdk-sharp.dll

class Tester {
	public static void Main() {
		System.Console.WriteLine("Checkpoint A");
		Gdk.Threads.Init ();
		System.Console.WriteLine("Checkpoint B");
		Gdk.Threads.Enter ();
		System.Console.WriteLine("Checkpoint C");
		Gdk.Threads.Enter ();
		System.Console.WriteLine("Checkpoint D");

When executing the program the response was:

> Checkpoint A
> Checkpoint B
> Checkpoint C

In other words, it stalls when it tries to enter the
2nd Gdk.Threads.Enter call. Is this correct behaviour?
Should it not do something like, the "user" calls
Enter twice, then he must call leave twice to release
the lock?

Hope somebody has an answer for me.


Mads LindstÝrm

Yahoo! Mail (http://dk.mail.yahoo.com) - Gratis: 6 MB lagerplads, spamfilter og virusscan