[gnome-shell] browser-plugin: Fix leak in plugin_enable_extension



commit c6e924f78863ee9d5e4957ce87d2af2cae77592e
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Wed Jan 25 01:26:47 2012 -0500

    browser-plugin: Fix leak in plugin_enable_extension
    
    https://bugzilla.gnome.org/show_bug.cgi?id=668541

 browser-plugin/browser-plugin.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/browser-plugin/browser-plugin.c b/browser-plugin/browser-plugin.c
index 799d863..de364d1 100644
--- a/browser-plugin/browser-plugin.c
+++ b/browser-plugin/browser-plugin.c
@@ -457,7 +457,10 @@ plugin_enable_extension (PluginObject *obj,
 {
   gchar *uuid_str = g_strndup (uuid.UTF8Characters, uuid.UTF8Length);
   if (!uuid_is_valid (uuid_str))
-    return FALSE;
+    {
+      g_free (uuid_str);
+      return FALSE;
+    }
 
   g_dbus_proxy_call (obj->proxy,
                      (enabled ? "EnableExtension" : "DisableExtension"),



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]