commit: 5868abe97babcc287794dcb36ad8e77989b6ddcf
Author: William Hubbs <w.d.hubbs <AT> gmail <DOT> com>
AuthorDate: Thu Feb 22 00:16:56 2018 +0000
Commit: William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Thu Feb 22 00:16:56 2018 +0000
URL: https://gitweb.gentoo.org/proj/openrc.git/commit/?id=5868abe9
start-stop-daemon: compiler warning cleanup
src/rc/start-stop-daemon.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/rc/start-stop-daemon.c b/src/rc/start-stop-daemon.c
index 88b1e091..1b565829 100644
--- a/src/rc/start-stop-daemon.c
+++ b/src/rc/start-stop-daemon.c
@@ -616,7 +616,8 @@ int main(int argc, char **argv)
fp = fopen(exec_file, "r");
if (fp) {
line = NULL;
- getline(&line, &size, fp);
+ if (getline(&line, &size, fp) == -1)
+ eerrorx("%s: %s", applet, strerror(errno));
p = line;
fclose(fp);
if (p != NULL && line[0] == '#' && line[1] == '!') {