aboutsummaryrefslogtreecommitdiffstats
path: root/src/blogc-runserver/main.c
diff options
context:
space:
mode:
authorRafael G. Martins <rafael@rafaelmartins.eng.br>2019-03-28 19:51:32 +0100
committerRafael G. Martins <rafael@rafaelmartins.eng.br>2019-03-28 19:51:32 +0100
commita7d888e158104ee7993921687457dc3b4ddd6c4b (patch)
tree8596b5e0bb7d34ef29ea4c7e6730390dd06faf80 /src/blogc-runserver/main.c
parent09139645e866b745c9f8797659f12c90af867015 (diff)
downloadblogc-a7d888e158104ee7993921687457dc3b4ddd6c4b.tar.gz
blogc-a7d888e158104ee7993921687457dc3b4ddd6c4b.tar.bz2
blogc-a7d888e158104ee7993921687457dc3b4ddd6c4b.zip
runserver: exit 1 on error
Diffstat (limited to 'src/blogc-runserver/main.c')
-rw-r--r--src/blogc-runserver/main.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/blogc-runserver/main.c b/src/blogc-runserver/main.c
index 64383a5..1c5be29 100644
--- a/src/blogc-runserver/main.c
+++ b/src/blogc-runserver/main.c
@@ -104,7 +104,7 @@ main(int argc, char **argv)
print_usage();
fprintf(stderr, "blogc-runserver: error: invalid "
"argument: -%c\n", argv[i][1]);
- rv = 3;
+ rv = 1;
goto cleanup;
}
}
@@ -113,7 +113,7 @@ main(int argc, char **argv)
print_usage();
fprintf(stderr, "blogc-runserver: error: only one positional "
"argument allowed\n");
- rv = 3;
+ rv = 1;
goto cleanup;
}
args++;
@@ -125,7 +125,7 @@ main(int argc, char **argv)
print_usage();
fprintf(stderr, "blogc-runserver: error: document root directory "
"required\n");
- rv = 3;
+ rv = 1;
goto cleanup;
}
@@ -133,7 +133,7 @@ main(int argc, char **argv)
print_usage();
fprintf(stderr, "blogc-runserver: error: invalid value for -m. "
"Must be integer > 0 and <= 1000\n");
- rv = 3;
+ rv = 1;
goto cleanup;
}