mirror of
https://github.com/brl/mutter.git
synced 2025-01-14 13:43:08 +00:00
core: Initialize g_autofree with NULL
This prevents build warnings about use of potentially uninitialized variables. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2301>
This commit is contained in:
parent
7734d6f56b
commit
2a5506170a
@ -642,7 +642,7 @@ meta_pad_action_mapper_handle_action (MetaPadActionMapper *mapper,
|
|||||||
{
|
{
|
||||||
MetaPadDirection direction = META_PAD_DIRECTION_NONE;
|
MetaPadDirection direction = META_PAD_DIRECTION_NONE;
|
||||||
g_autoptr (GSettings) settings1 = NULL, settings2 = NULL;
|
g_autoptr (GSettings) settings1 = NULL, settings2 = NULL;
|
||||||
g_autofree char *accel1, *accel2;
|
g_autofree char *accel1 = NULL, *accel2 = NULL;
|
||||||
gboolean handled;
|
gboolean handled;
|
||||||
|
|
||||||
if (action == META_PAD_ACTION_RING)
|
if (action == META_PAD_ACTION_RING)
|
||||||
@ -748,7 +748,7 @@ compose_directional_action_label (MetaPadDirection direction1,
|
|||||||
MetaPadDirection direction2,
|
MetaPadDirection direction2,
|
||||||
GSettings *value2)
|
GSettings *value2)
|
||||||
{
|
{
|
||||||
g_autofree char *accel1, *accel2;
|
g_autofree char *accel1 = NULL, *accel2 = NULL;
|
||||||
GString *str;
|
GString *str;
|
||||||
|
|
||||||
accel1 = g_settings_get_string (value1, "keybinding");
|
accel1 = g_settings_get_string (value1, "keybinding");
|
||||||
|
Loading…
Reference in New Issue
Block a user