mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-05 16:20:10 +00:00
Avoid a segfault if license is NULL
The license field was introduced later on, so some out-of-tree loaders may not set it. And Solaris printf() doesn't take NULL for a string... Bug 594178.
This commit is contained in:
parent
1c0ecc0380
commit
079cc21956
@ -119,17 +119,20 @@ loader_sanity_check (const char *path, GdkPixbufFormat *info, GdkPixbufModule *v
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void
|
||||
static void
|
||||
write_loader_info (const char *path, GdkPixbufFormat *info)
|
||||
{
|
||||
const GdkPixbufModulePattern *pattern;
|
||||
char **mime;
|
||||
char **ext;
|
||||
char **mime;
|
||||
char **ext;
|
||||
|
||||
g_printf("\"%s\"\n", path);
|
||||
g_printf ("\"%s\" %u \"%s\" \"%s\" \"%s\"\n",
|
||||
info->name, info->flags,
|
||||
info->domain ? info->domain : GETTEXT_PACKAGE, info->description, info->license);
|
||||
g_printf ("\"%s\" %u \"%s\" \"%s\" \"%s\"\n",
|
||||
info->name,
|
||||
info->flags,
|
||||
info->domain ? info->domain : GETTEXT_PACKAGE,
|
||||
info->description,
|
||||
info->license ? info->license : "");
|
||||
for (mime = info->mime_types; *mime; mime++) {
|
||||
g_printf ("\"%s\" ", *mime);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user