shell: Do not forcibly suppress debug messages if --verbose not set
Only force G_MESSAGES_DEBUG=all on --verbose, and follow the usual logging behaviour otherwise. This fixes specifying log domains in G_MESSAGES_DEBUG and also G_MESSAGES_DEBUG=all without setting --verbose. https://bugzilla.gnome.org/show_bug.cgi?id=693732
This commit is contained in:
parent
f064b653df
commit
30144e58f3
1 changed files with 1 additions and 3 deletions
|
@ -54,12 +54,10 @@ cc_shell_log_init (void)
|
||||||
void
|
void
|
||||||
cc_shell_log_set_debug (gboolean debug)
|
cc_shell_log_set_debug (gboolean debug)
|
||||||
{
|
{
|
||||||
g_setenv ("G_MESSAGES_DEBUG", "all", TRUE);
|
|
||||||
|
|
||||||
if (debug) {
|
if (debug) {
|
||||||
|
g_setenv ("G_MESSAGES_DEBUG", "all", TRUE);
|
||||||
log_levels |= (G_LOG_LEVEL_DEBUG | G_LOG_LEVEL_INFO);
|
log_levels |= (G_LOG_LEVEL_DEBUG | G_LOG_LEVEL_INFO);
|
||||||
g_debug ("Enabling debugging");
|
g_debug ("Enabling debugging");
|
||||||
} else {
|
|
||||||
log_levels &= ~ (G_LOG_LEVEL_DEBUG | G_LOG_LEVEL_INFO);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue