[gimp/gimp-2-6] app: fix use of GIMP_LOG=help



commit 727b1a1151e146c9d4724d830451137fdf9aa3e0
Author: Sven Neumann <sven gimp org>
Date:   Tue May 26 12:23:26 2009 +0200

    app: fix use of GIMP_LOG=help
    
    g_parse_debug_string() has special treatment of the string 'help',
    but we want to use it for the GIMP_LOG_HELP domain.
    (cherry picked from commit a427213fb8ac54768b1a25261aec3da6e97ad421)
---
 app/gimp-log.c |   12 +++++++++---
 1 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/app/gimp-log.c b/app/gimp-log.c
index 95ea7c3..c51e0bd 100644
--- a/app/gimp-log.c
+++ b/app/gimp-log.c
@@ -47,9 +47,15 @@ gimp_log_init (void)
         { "scale",          GIMP_LOG_SCALE          }
       };
 
-      gimp_log_flags = g_parse_debug_string (env_log_val,
-                                             log_keys,
-                                             G_N_ELEMENTS (log_keys));
+      /*  g_parse_debug_string() has special treatment of the string 'help',
+       *  but we want to use it for the GIMP_LOG_HELP domain
+       */
+      if (g_ascii_strcasecmp (env_log_val, "help") == 0)
+        gimp_log_flags = GIMP_LOG_HELP;
+      else
+        gimp_log_flags = g_parse_debug_string (env_log_val,
+                                               log_keys,
+                                               G_N_ELEMENTS (log_keys));
     }
 }
 



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