From 69ff3f7a28f0d81ae1706834337b089ddf109e80 Mon Sep 17 00:00:00 2001 From: Bill Nottingham Date: Tue, 7 Mar 2000 17:19:49 +0000 Subject: don't ignore stat return code --- src/minilogd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/minilogd.c') diff --git a/src/minilogd.c b/src/minilogd.c index 09cd2f03..aba5e7c5 100644 --- a/src/minilogd.c +++ b/src/minilogd.c @@ -82,7 +82,8 @@ void runDaemon(int sock) { done = 0; /* Get stat info on /dev/log so we can later check to make sure we * still own it... */ - stat(_PATH_LOG,&s1); + if (stat(_PATH_LOG,&s1) != 0) + memset(&s1, '\0', sizeof(struct stat)); while (!done) { pfds.fd = sock; pfds.events = POLLIN|POLLPRI; -- cgit v1.2.1