]> git.ipfire.org Git - thirdparty/lldpd.git/commitdiff
coverity: if we cannot read /etc/localtime, don't go further
authorVincent Bernat <bernat@luffy.cx>
Fri, 22 Nov 2013 23:44:08 +0000 (00:44 +0100)
committerVincent Bernat <bernat@luffy.cx>
Fri, 22 Nov 2013 23:44:08 +0000 (00:44 +0100)
src/daemon/priv.c

index e412d542bbba07c7385722c7cc0d7a78c5c7bbc3..703489f0ccc229cb6d805d1d3f9901689b9d5def 100644 (file)
@@ -458,6 +458,8 @@ priv_setup_chroot(const char *chrootdir)
        if ((source = open(LOCALTIME, O_RDONLY)) == -1) {
                if (errno == ENOENT)
                        return;
+               log_warn("privsep", "cannot read " LOCALTIME);
+               return;
        }
 
        /* Prepare copy of /etc/localtime */