From: Andre Noll <maan@systemlinux.org>
Date: Sun, 29 Jul 2012 14:28:28 +0000 (+0200)
Subject: para_gui ggo: Do not pass --no-handle-error.
X-Git-Tag: v0.4.12~21
X-Git-Url: https://git.tuebingen.mpg.de/?a=commitdiff_plain;h=eb4d66692d738c7613333ef4dfb5b19fb17ab299;p=paraslash.git

para_gui ggo: Do not pass --no-handle-error.

We are exiting anyway on errors. This change allows to skip
the check of the return value of gui_cmdline_parser() and
removes a line from the makefile.
---

diff --git a/gui.c b/gui.c
index 65b2ac05..a8a7fc9f 100644
--- a/gui.c
+++ b/gui.c
@@ -1486,8 +1486,7 @@ int main(int argc, char *argv[])
 	_argc = argc;
 	_argv = argv;
 
-	if (gui_cmdline_parser(argc, argv, &conf) != 0)
-		exit(EXIT_FAILURE);
+	gui_cmdline_parser(argc, argv, &conf); /* exits on errors */
 	HANDLE_VERSION_FLAG("gui", conf);
 	cf = configfile_exists();
 	if (!cf && conf.config_file_given) {
diff --git a/m4/gengetopt/makefile b/m4/gengetopt/makefile
index 316ef47b..a887ab76 100644
--- a/m4/gengetopt/makefile
+++ b/m4/gengetopt/makefile
@@ -27,7 +27,6 @@ $(cmdline_dir)/%_write.cmdline.h $(cmdline_dir)/%_write.cmdline.c: $(ggo_dir)/%_
 		--func-name $(subst _write.ggo,,$(<F))_cmdline_parser < $<
 
 define ggo-opts
-$(if $(filter gui,$(*F)), --no-handle-error) \
 $(if $(filter recv filter write audiod,$(*F)), --no-handle-help) \
 $(if $(filter afh,$(*F)), --unamed-opts=audio_file) \
 $(if $(filter client audioc,$(*F)), --unamed-opts=command) \