mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-14 05:16:18 +01:00
Merge branch 'compiler-warnings' into 'master'
Fix a couple of wrong compiler warnings See merge request GNOME/glib!615
This commit is contained in:
commit
f5541d8a6e
@ -909,7 +909,7 @@ _g_io_module_get_default (const gchar *extension_point,
|
|||||||
const char *use_this;
|
const char *use_this;
|
||||||
GList *l;
|
GList *l;
|
||||||
GIOExtensionPoint *ep;
|
GIOExtensionPoint *ep;
|
||||||
GIOExtension *extension, *preferred;
|
GIOExtension *extension = NULL, *preferred;
|
||||||
gpointer impl;
|
gpointer impl;
|
||||||
|
|
||||||
g_rec_mutex_lock (&default_modules_lock);
|
g_rec_mutex_lock (&default_modules_lock);
|
||||||
@ -986,9 +986,12 @@ _g_io_module_get_default (const gchar *extension_point,
|
|||||||
g_rec_mutex_unlock (&default_modules_lock);
|
g_rec_mutex_unlock (&default_modules_lock);
|
||||||
|
|
||||||
if (impl != NULL)
|
if (impl != NULL)
|
||||||
|
{
|
||||||
|
g_assert (extension != NULL);
|
||||||
g_debug ("%s: Found default implementation %s (%s) for ‘%s’",
|
g_debug ("%s: Found default implementation %s (%s) for ‘%s’",
|
||||||
G_STRFUNC, g_io_extension_get_name (extension),
|
G_STRFUNC, g_io_extension_get_name (extension),
|
||||||
G_OBJECT_TYPE_NAME (impl), extension_point);
|
G_OBJECT_TYPE_NAME (impl), extension_point);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
g_debug ("%s: Failed to find default implementation for ‘%s’",
|
g_debug ("%s: Failed to find default implementation for ‘%s’",
|
||||||
G_STRFUNC, extension_point);
|
G_STRFUNC, extension_point);
|
||||||
|
@ -155,7 +155,7 @@ test_default (void)
|
|||||||
static void
|
static void
|
||||||
test_fallback (void)
|
test_fallback (void)
|
||||||
{
|
{
|
||||||
GAppInfo *info1, *info2, *app;
|
GAppInfo *info1, *info2, *app = NULL;
|
||||||
GList *apps, *recomm, *fallback, *list, *l, *m;
|
GList *apps, *recomm, *fallback, *list, *l, *m;
|
||||||
GError *error = NULL;
|
GError *error = NULL;
|
||||||
gint old_length;
|
gint old_length;
|
||||||
@ -188,6 +188,7 @@ test_fallback (void)
|
|||||||
if (g_app_info_equal (info1, app))
|
if (g_app_info_equal (info1, app))
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
g_assert_nonnull (app);
|
||||||
g_assert_true (g_app_info_equal (info1, app));
|
g_assert_true (g_app_info_equal (info1, app));
|
||||||
|
|
||||||
/* and that Test2 is among the fallback apps */
|
/* and that Test2 is among the fallback apps */
|
||||||
|
Loading…
Reference in New Issue
Block a user