From: Lennart Poettering Date: Mon, 22 Jan 2018 14:29:30 +0000 (+0100) Subject: tmpfiles: fold five lines into two X-Git-Tag: v237~57^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ecc1709c2c216ef9e3035dac3b40abfcc6609094;p=platform%2Fupstream%2Fsystemd.git tmpfiles: fold five lines into two log_full_errno() has all these nice benefits, let's make use of them to shorten five lines into two. --- diff --git a/src/tmpfiles/tmpfiles.c b/src/tmpfiles/tmpfiles.c index 96ffa42..66dabc7 100644 --- a/src/tmpfiles/tmpfiles.c +++ b/src/tmpfiles/tmpfiles.c @@ -547,11 +547,8 @@ static int dir_cleanup( continue; /* FUSE, NFS mounts, SELinux might return EACCES */ - if (errno == EACCES) - log_debug_errno(errno, "stat(%s/%s) failed: %m", p, dent->d_name); - else - log_error_errno(errno, "stat(%s/%s) failed: %m", p, dent->d_name); - r = -errno; + r = log_full_errno(errno == EACCES ? LOG_DEBUG : LOG_ERR, errno, + "stat(%s/%s) failed: %m", p, dent->d_name); continue; }