Always use Glib error directly if gtk_init failed

This commit is contained in:
Christian Dywan 2008-09-23 17:16:22 +02:00
parent 0943ac252e
commit 7c4480ca53

View file

@ -504,10 +504,7 @@ main (int argc,
if (!gtk_init_with_args (&argc, &argv, _("[URIs]"), entries, if (!gtk_init_with_args (&argc, &argv, _("[URIs]"), entries,
GETTEXT_PACKAGE, &error)) GETTEXT_PACKAGE, &error))
{ {
if (error->code == G_OPTION_ERROR_UNKNOWN_OPTION) g_print ("%s - %s\n", _("Midori"), error->message);
g_print ("%s - %s\n", _("Midori"), _("Unknown argument."));
else
g_print ("%s - %s", _("Midori"), _("Failed to setup interface."));
g_error_free (error); g_error_free (error);
return 1; return 1;
} }