Re: gdk_pixbuf_loader_write and short files

----- Original Message -----
From: "Havoc Pennington" <hp redhat com>
To: <matthiasc poet de>
Cc: <gtk-devel-list gnome org>
Sent: Tuesday, August 28, 2001 10:30 PM
Subject: Re: gdk_pixbuf_loader_write and short files

> Matthias Clasen <matthiasc poet de> writes:
> > +    retval = gdk_pixbuf_loader_load_module (loader, NULL, error);
> >
> We need to be sure we always return without reusing "error" here.
> i.e. if there's an error stop_load should not be called.

Thats why I added retval as a condition in the following if, maybe you
missed that.
I was under the impression that gdk_pixbuf_loader_load_module would
return false if it an error occurred, in addition to possibly setting error.

Speaking about GError. In the low mem tests of test-loaders, I encountered
the interesting situation that the loader tries to use g_set_error to report
out-of-memory situation - and then g_set_error falls on its face because it
tries to allocate some more memory for duplicating the message.

Is there anything that can be done about this ?
Other than using a very short message like "OOM"...


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