pidgin/gtkutils.c

branch
release-2.x.y
changeset 40914
3e498730f8ca
parent 40841
d12f1daf83ff
child 42586
488055ab5531
--- a/pidgin/gtkutils.c	Tue Jun 01 20:22:06 2021 -0500
+++ b/pidgin/gtkutils.c	Tue Jun 01 22:18:49 2021 -0500
@@ -3245,7 +3245,6 @@
 	}
 #else
 	char *command = NULL;
-	char *tmp = NULL;
 	GError *error = NULL;
 
 	if (purple_running_gnome())
@@ -3275,8 +3274,8 @@
 		gint exit_status;
 		if (!g_spawn_command_line_sync(command, NULL, NULL, &exit_status, &error))
 		{
-			tmp = g_strdup_printf(_("Error launching %s: %s"),
-							filename, error->message);
+			gchar *tmp = g_strdup_printf(_("Error launching %s: %s"),
+			                             filename, error->message);
 			purple_notify_error(imhtml, NULL, _("Unable to open file."), tmp);
 			g_free(tmp);
 			g_error_free(error);
@@ -3287,7 +3286,6 @@
 			char *secondary = g_strdup_printf(_("Process returned error code %d"),
 									exit_status);
 			purple_notify_error(imhtml, NULL, primary, secondary);
-			g_free(tmp);
 		}
 	}
 #endif

mercurial