summaryrefslogtreecommitdiffstats
path: root/gtk-gui.c
diff options
context:
space:
mode:
authorGravatar Linus Torvalds <torvalds@linux-foundation.org>2011-11-01 17:09:15 -0700
committerGravatar Linus Torvalds <torvalds@linux-foundation.org>2011-11-01 17:09:15 -0700
commite4bfb6597279ca3d9aa3678a617f5f0aef298278 (patch)
tree6262f40ce2aca37fc8b7aa63905d3c190be173cb /gtk-gui.c
parent43601f654675c8734c9ca5850cc41dac16d1989a (diff)
downloadsubsurface-e4bfb6597279ca3d9aa3678a617f5f0aef298278.tar.gz
Fix 'init_ui()' so that it can change argc/argv
That's what gtk_init() does with gtk-specific arguments. IOW, if you do things like subsurface --g-fatal-warnings dives.xml to get a real abort on gtk warnings, gtk_init needs to be able to actually change argc/argv. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'gtk-gui.c')
-rw-r--r--gtk-gui.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gtk-gui.c b/gtk-gui.c
index b16050838..676c0d063 100644
--- a/gtk-gui.c
+++ b/gtk-gui.c
@@ -739,7 +739,7 @@ static int get_from_registry(HKEY hkey, const char *key)
}
#endif
-void init_ui(int argc, char **argv)
+void init_ui(int *argcp, char ***argvp)
{
GtkWidget *win;
GtkWidget *notebook;
@@ -755,7 +755,7 @@ void init_ui(int argc, char **argv)
"GTK_NOTEBOOK_TAB", GTK_TARGET_SAME_APP, 0
};
- gtk_init(&argc, &argv);
+ gtk_init(argcp, argvp);
settings = gtk_settings_get_default();
gtk_settings_set_long_property(settings, "gtk_tooltip_timeout", 10, "subsurface setting");