aboutsummaryrefslogtreecommitdiffstats
path: root/src/blogc-git-receiver/post-receive.c
diff options
context:
space:
mode:
authorRafael G. Martins <rafael@rafaelmartins.eng.br>2019-03-28 19:57:12 +0100
committerRafael G. Martins <rafael@rafaelmartins.eng.br>2019-03-28 19:57:12 +0100
commit81acc30ee998ce7eb05df0e4216b3d994a5b30f2 (patch)
tree3ed29e9c821256e8654819e9ae611f5b683425df /src/blogc-git-receiver/post-receive.c
parenta7d888e158104ee7993921687457dc3b4ddd6c4b (diff)
downloadblogc-81acc30ee998ce7eb05df0e4216b3d994a5b30f2.tar.gz
blogc-81acc30ee998ce7eb05df0e4216b3d994a5b30f2.tar.bz2
blogc-81acc30ee998ce7eb05df0e4216b3d994a5b30f2.zip
git-receiver: exit 1 on error
Diffstat (limited to 'src/blogc-git-receiver/post-receive.c')
-rw-r--r--src/blogc-git-receiver/post-receive.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/blogc-git-receiver/post-receive.c b/src/blogc-git-receiver/post-receive.c
index b5e1f81..17a8aa7 100644
--- a/src/blogc-git-receiver/post-receive.c
+++ b/src/blogc-git-receiver/post-receive.c
@@ -29,14 +29,14 @@ bgr_post_receive_hook(int argc, char *argv[])
if (real_hooks_dir == NULL) {
fprintf(stderr, "error: failed to guess repository root: %s\n",
strerror(errno));
- return 3;
+ return 1;
}
char *repo_path = bc_strdup(dirname(real_hooks_dir));
free(real_hooks_dir);
if (0 != chdir(repo_path)) {
fprintf(stderr, "error: failed to change to repository root\n");
- rv = 3;
+ rv = 1;
goto cleanup;
}