[Mono-list] Using gdk;

Mike Cleaver mike at moga.to
Tue Aug 5 03:07:39 EDT 2008


Sorry people I'm stuck on one more problem using 2.0 beta,

I am resizing images using Gdk, running on OSX (from package) (same  
code runs without error on Ubuntu + 2.0b compiled from source) and get  
the console readout:

(bin/server.exe:31844): GLib-GObject-CRITICAL **: gtype.c:2242:  
initialization assertion failed, use g_type_init() prior to this  
function

(bin/server.exe:31844): GLib-CRITICAL **: g_once_init_leave: assertion  
`initialization_value != 0' failed

(bin/server.exe:31844): GLib-GObject-CRITICAL **: g_object_new:  
assertion `G_TYPE_IS_OBJECT (object_type)' failed
Stacktrace:

I have called Gdk.Global.InitCheck(ref args); in an init method,
and the error occurs when calling:

			Gdk.PixbufLoader loader = new Gdk.PixbufLoader ();
			byte [] buffer = new byte [8192];
			int n;

			while ((n = input.Read (buffer, 0, 8192)) != 0)
->				loader.Write (buffer, (ulong) n);

Is there some GLib Init method that I need to be calling? Any ideas?

Thanks,


Mike Cleaver
mike at moga.to




More information about the Mono-list mailing list