[gimp] app: run errors_init() after gimp_load_config().
- From: Jehan Pagès <jehanp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app: run errors_init() after gimp_load_config().
- Date: Sun, 25 Mar 2018 23:28:10 +0000 (UTC)
commit 9f3ee499c1e6ca27032a47f5b1ad2b8b6dd968eb
Author: Jehan <jehan girinstud io>
Date: Mon Mar 26 01:22:36 2018 +0200
app: run errors_init() after gimp_load_config().
Since error handling is based on preferences, the config needs to be
loaded first. Otherwise the gimp->config object does not exist yet and
we get a bunch of "'G_IS_OBJECT (object)' failed" assertion which
recurse in error handling when trying to get the "debug-policy"
property.
Just init the error handling later. It means it won't handle early
loading code, but that is not much of an issue.
app/app.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
---
diff --git a/app/app.c b/app/app.c
index d7a7f76..7296b0b 100644
--- a/app/app.c
+++ b/app/app.c
@@ -276,18 +276,21 @@ app_run (const gchar *full_prog_name,
g_object_unref (gimpdir);
+ gimp_load_config (gimp, alternate_system_gimprc, alternate_gimprc);
+
/* Initialize the error handling after creating/migrating the config
* directory because it will create some folders for backup and crash
* logs in advance. Therefore running this before
* gimp_user_install_new() would break migration as well as initial
* folder creations.
+ *
+ * It also needs to be run after gimp_load_config() because error
+ * handling is based on Preferences. It means that early loading code
+ * is not handled by our debug code, but that's not a big deal.
*/
errors_init (gimp, full_prog_name, use_debug_handler,
stack_trace_mode, backtrace_file);
-
- gimp_load_config (gimp, alternate_system_gimprc, alternate_gimprc);
-
/* run the late-stage sanity check. it's important that this check is run
* after the call to language_init() (see comment in sanity_check_late().)
*/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]