pidgin/pidgin

Parents 0c1c063d71f6
Children 590d533cf290
Fix console logging and turn it on unconditionally if we're doing a debug build

Testing Done:
Ran `ninja reconfigure` with a debug buildtype (which is the default build type) with console-logging on and off and verified it was turned on. Also ran `ninja reconfigure` with a release buildtype and verified that the `console-logging` option was honored.

Reviewed at https://reviews.imfreedom.org/r/1004/
--- a/libpurple/debug.c Thu Oct 07 22:24:25 2021 -0500
+++ b/libpurple/debug.c Thu Oct 07 22:28:08 2021 -0500
@@ -66,10 +66,6 @@
return;
}
- if(!purple_debug_ui_is_enabled(ui, level, category)) {
- return;
- }
-
arg_s = g_strdup_vprintf(format, args);
g_strchomp(arg_s); /* strip trailing linefeeds */
@@ -113,7 +109,9 @@
g_free(ts_s);
}
- purple_debug_ui_print(ui, level, category, arg_s);
+ if(purple_debug_ui_is_enabled(ui, level, category)) {
+ purple_debug_ui_print(ui, level, category, arg_s);
+ }
g_free(arg_s);
}
--- a/meson.build Thu Oct 07 22:24:25 2021 -0500
+++ b/meson.build Thu Oct 07 22:28:08 2021 -0500
@@ -654,7 +654,11 @@
# check for gtk-doc
ENABLE_DOC = get_option('doc')
-enable_debug = get_option('console-logging')
+if ['debug', 'debugoptimize'].contains(get_option('buildtype'))
+ enable_debug = true
+else
+ enable_debug = get_option('console-logging')
+endif
conf.set('DEBUG', enable_debug)
# So that config.h may be found.