mirror of
https://github.com/brl/mutter.git
synced 2025-06-13 16:59:30 +00:00
Fix builds with G_DISABLE_ASSERT
Commit 25f416c13d
added additional compilation warnings, including
-Werror=return-type. There are several places where this results
in build failures if `g_assert_not_reached()` is disabled at compile
time and the compiler misses a return value.
https://gitlab.gnome.org/GNOME/mutter/issues/447
This commit is contained in:
@ -994,6 +994,7 @@ get_connector_type_name (MetaConnectorType connector_type)
|
||||
case META_CONNECTOR_TYPE_DSI: return "DSI";
|
||||
default: g_assert_not_reached ();
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static GList *
|
||||
|
@ -37,4 +37,5 @@ meta_monitor_transform_invert (MetaMonitorTransform transform)
|
||||
return transform;
|
||||
}
|
||||
g_assert_not_reached ();
|
||||
return 0;
|
||||
}
|
||||
|
@ -479,6 +479,7 @@ discrete_steps_to_scroll_direction (unsigned int axis,
|
||||
return CLUTTER_SCROLL_RIGHT;
|
||||
|
||||
g_assert_not_reached ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
|
@ -924,6 +924,7 @@ is_cursor_hw_state_valid (MetaCursorSprite *cursor_sprite,
|
||||
}
|
||||
|
||||
g_assert_not_reached ();
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
#ifdef HAVE_WAYLAND
|
||||
|
@ -173,6 +173,7 @@ meta_monitor_transform_to_xrandr (MetaMonitorTransform transform)
|
||||
}
|
||||
|
||||
g_assert_not_reached ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
|
@ -70,6 +70,7 @@ get_x11_cogl_winsys_vtable (CoglRenderer *renderer)
|
||||
break;
|
||||
}
|
||||
g_assert_not_reached ();
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static CoglRenderer *
|
||||
|
Reference in New Issue
Block a user