summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorguenther <guenther@openbsd.org>2013-05-15 22:46:00 +0000
committerguenther <guenther@openbsd.org>2013-05-15 22:46:00 +0000
commit9c85baa2ce72ff177f50a7e15eb2312261331d03 (patch)
treec0f438a87007da91f28bbb815ce7c16db01bf04c
parentremove unused splaudio/splx pair (diff)
downloadwireguard-openbsd-9c85baa2ce72ff177f50a7e15eb2312261331d03.tar.xz
wireguard-openbsd-9c85baa2ce72ff177f50a7e15eb2312261331d03.zip
If execing an /etc/apm/* program fails, log the failure and error message.
ok tedu@ kettenis@
-rw-r--r--usr.sbin/apmd/apmd.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.sbin/apmd/apmd.c b/usr.sbin/apmd/apmd.c
index 1c157584ff1..9895fe75770 100644
--- a/usr.sbin/apmd/apmd.c
+++ b/usr.sbin/apmd/apmd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: apmd.c,v 1.59 2013/04/29 00:28:23 okan Exp $ */
+/* $OpenBSD: apmd.c,v 1.60 2013/05/15 22:46:00 guenther Exp $ */
/*
* Copyright (c) 1995, 1996 John T. Kohl
@@ -782,6 +782,7 @@ do_etc_file(const char *file)
case 0:
/* We are the child. */
execl(file, prog, (char *)NULL);
+ syslog(LOG_ERR, "failed to exec %s: %m", file);
_exit(1);
/* NOTREACHED */
default: