[med-svn] [aghermann] 17/85: common/fs: use lstat instead of stat

andrei zavada hmmr-guest at alioth.debian.org
Thu Sep 26 23:46:24 UTC 2013


This is an automated email from the git hooks/post-receive script.

hmmr-guest pushed a commit to branch master
in repository aghermann.

commit 89aa2854ec4f770cf2ee1d67a0a1eda18d3ae29d
Author: Andrei Zavada <johnhommer at gmail.com>
Date:   Tue Sep 10 02:21:31 2013 +0300

    common/fs: use lstat instead of stat
---
 upstream/src/common/fs.hh |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/upstream/src/common/fs.hh b/upstream/src/common/fs.hh
index 2dd5f4d..394db72 100644
--- a/upstream/src/common/fs.hh
+++ b/upstream/src/common/fs.hh
@@ -54,7 +54,7 @@ inline bool
 exists_and_is_writable( const string& dir)
 {
         struct stat attr;
-        return stat( dir.c_str(), &attr) == 0 &&
+        return lstat( dir.c_str(), &attr) == 0 &&
                 S_ISDIR (attr.st_mode) &&
                 (attr.st_mode & S_IWUSR) &&
                 (attr.st_uid == getuid());

-- 
Alioth's /git/debian-med/git-commit-notice on /srv/git.debian.org/git/debian-med/aghermann.git



More information about the debian-med-commit mailing list