From 562cf142584117481260aaa5c6f2c3e93fb84229 Mon Sep 17 00:00:00 2001 From: Olivier Fourdan Date: Wed, 23 Jan 2019 09:29:39 +0100 Subject: [PATCH] core: Fix compiler warning MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fix compiler warning: ‘startup_id’ may be used uninitialized in `meta_launch_context_get_startup_notify_id()`. Also change `gchar` to plain `char` while at it. https://gitlab.gnome.org/GNOME/mutter/merge_requests/406 --- src/core/meta-launch-context.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/core/meta-launch-context.c b/src/core/meta-launch-context.c index d70f5a5e7..eb8671bb2 100644 --- a/src/core/meta-launch-context.c +++ b/src/core/meta-launch-context.c @@ -127,7 +127,7 @@ meta_launch_context_get_startup_notify_id (GAppLaunchContext *launch_context, MetaLaunchContext *context = META_LAUNCH_CONTEXT (launch_context); MetaDisplay *display = context->display; int workspace_idx = -1; - gchar *startup_id; + char *startup_id = NULL; if (context->workspace) workspace_idx = meta_workspace_index (context->workspace); @@ -148,7 +148,7 @@ meta_launch_context_get_startup_notify_id (GAppLaunchContext *launch_context, if (!startup_id) { - const gchar *application_id = NULL; + const char *application_id = NULL; MetaStartupNotification *sn; MetaStartupSequence *seq;