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:
Florian Müllner
2019-01-25 00:47:44 +01:00
parent de41f3ea28
commit d5a7bbd094
20 changed files with 25 additions and 0 deletions

View File

@ -1832,6 +1832,7 @@ positioner_anchor_to_placement_anchor (uint32_t anchor)
return (META_PLACEMENT_ANCHOR_BOTTOM | META_PLACEMENT_ANCHOR_RIGHT);
default:
g_assert_not_reached ();
return META_PLACEMENT_ANCHOR_NONE;
}
}
@ -1860,6 +1861,7 @@ positioner_gravity_to_placement_gravity (uint32_t gravity)
return (META_PLACEMENT_GRAVITY_BOTTOM | META_PLACEMENT_GRAVITY_RIGHT);
default:
g_assert_not_reached ();
return META_PLACEMENT_GRAVITY_NONE;
}
}