summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/wsman.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/wsman.c b/src/wsman.c
index 0b4de46..a73697b 100644
--- a/src/wsman.c
+++ b/src/wsman.c
@@ -359,11 +359,16 @@ static char wsman_parse_options(int argc, char **argv)
retval = u_option_context_parse(opt_ctx, &argc, &argv, &error);
u_option_context_free(opt_ctx);
- if (error) {
+ if (retval == 0) {
+ if (error) {
if (error->message)
- printf("%s\n", error->message);
+ fprintf(stderr, "%s\n", error->message);
u_error_free(error);
- return FALSE;
+ }
+ else {
+ fprintf(stderr, "Can't parse context information\n");
+ }
+ return FALSE;
}
if (my_version) {