summary refs log tree commit diff
diff options
context:
space:
mode:
authorDuncaen <mail@duncano.de>2017-04-05 19:44:35 +0200
committerDuncaen <mail@duncano.de>2018-06-20 18:02:46 +0200
commit0b85cd8b88c92f6fe30a50ae46c796c68f4f77e9 (patch)
treed23b3d936b658a6d295538db19f2ca7a3eece84a
parent42ad2206322dece60094974eb3389e6816229111 (diff)
downloadrunit-void-0b85cd8b88c92f6fe30a50ae46c796c68f4f77e9.tar.gz
runit-void-0b85cd8b88c92f6fe30a50ae46c796c68f4f77e9.tar.xz
runit-void-0b85cd8b88c92f6fe30a50ae46c796c68f4f77e9.zip
vlogger: exit if exec fails
-rw-r--r--vlogger.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/vlogger.c b/vlogger.c
index 32a8ddb..4fd407a 100644
--- a/vlogger.c
+++ b/vlogger.c
@@ -97,8 +97,11 @@ main(int argc, char *argv[])
 			exit(1);
 		}
 
-	if (access("/etc/vlogger", X_OK) != -1)
+	if (access("/etc/vlogger", X_OK) != -1) {
 		execl("/etc/vlogger", argv0, tag, (char *)0);
+		fprintf(stderr, "vlogger: exec: %s\n", strerror(errno));
+		exit(1);
+	}
 
 	openlog(tag, 0, facility);