[metacity] libmetacity: remove debug code



commit a4d5554fa25db45174e23331ecab725a21b4ccbc
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date:   Wed Jan 27 23:31:22 2016 +0200

    libmetacity: remove debug code

 libmetacity/meta-color-spec.c |   27 +++++----------------------
 1 files changed, 5 insertions(+), 22 deletions(-)
---
diff --git a/libmetacity/meta-color-spec.c b/libmetacity/meta-color-spec.c
index e8add5a..8801e81 100644
--- a/libmetacity/meta-color-spec.c
+++ b/libmetacity/meta-color-spec.c
@@ -233,22 +233,13 @@ meta_color_spec_new_from_string (const gchar  *str,
 
   if (strncmp (str, "gtk:custom", 10) == 0)
     {
-      MetaColorSpec *fallback;
-      static gboolean debug_set;
-      static gboolean debug;
       const gchar *color_name_start;
       const gchar *fallback_str_start;
       const gchar *end;
+      gchar *fallback_str;
+      MetaColorSpec *fallback;
       gchar *color_name;
 
-      fallback = NULL;
-
-      if (!debug_set)
-        {
-          debug = g_getenv ("METACITY_DISABLE_FALLBACK_COLOR") != NULL;
-          debug_set = TRUE;
-        }
-
       if (str[10] != '(')
         {
           g_set_error (error, META_THEME_ERROR, META_THEME_ERROR_FAILED,
@@ -284,17 +275,9 @@ meta_color_spec_new_from_string (const gchar  *str,
           return NULL;
         }
 
-      if (!debug)
-        {
-          gchar *fallback_str;
-          fallback_str = g_strndup (fallback_str_start, end - fallback_str_start);
-          fallback = meta_color_spec_new_from_string (fallback_str, error);
-          g_free (fallback_str);
-        }
-      else
-        {
-          fallback = meta_color_spec_new_from_string ("pink", error);
-        }
+      fallback_str = g_strndup (fallback_str_start, end - fallback_str_start);
+      fallback = meta_color_spec_new_from_string (fallback_str, error);
+      g_free (fallback_str);
 
       if (fallback == NULL)
         return NULL;


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