Package: openbox Version: 3.6.1-10 Control: forwarded -1 https://bugzilla.icculus.org/show_bug.cgi?id=6447 Control: tags -1 + patch
When i right-click the openbox desktop menu and choose "reconfigure",
openbox produces the following message to stderr:
```
***** Imlib2 Developer Warning ***** :
This program is calling the Imlib call:
imlib_free_image();
With the parameter:
image
being NULL. Please fix your program.
ObRender-Message: Cannot load image "/usr/share/pixmaps/isympy.xpm" from file
"/usr/share/pixmaps/isympy.xpm"
```
I looked in the openbox source and found this invocation:
https://sources.debian.org/src/openbox/3.6.1-10/obrender/image.c/?hl=484#L484
```
void DestroyImlibLoader(ImlibLoader *loader)
{
if (!loader)
return;
imlib_free_image();
g_slice_free(ImlibLoader, loader);
}
```
I found a report in the upstream bugtracker, and found the report linked
above, which also contains the attached patch from "Grant" from over 5
years ago. I haven't tested it, but it looks reasonable to me.
--dkg
diff --git a/obrender/image.c b/obrender/image.c
index cffbaf3..5c689c4 100644
--- a/obrender/image.c
+++ b/obrender/image.c
@@ -476,17 +476,18 @@ struct _ImlibLoader
Imlib_Image img;
};
void DestroyImlibLoader(ImlibLoader *loader)
{
if (!loader)
return;
- imlib_free_image();
+ if (loader->img)
+ imlib_free_image();
g_slice_free(ImlibLoader, loader);
}
ImlibLoader* LoadWithImlib(gchar *path,
RrPixel32 **pixel_data,
gint *width,
gint *height)
{
signature.asc
Description: PGP signature

