From 7fa6b4e7692926d2d07adee1ef8e277157929058 Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Tue, 19 Apr 2005 13:59:17 -0700 Subject: [PATCH] Fix init-db shared database case Noted by Aaron Straus --- init-db.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/init-db.c b/init-db.c index ff2b11a3b..65898fa58 100644 --- a/init-db.c +++ b/init-db.c @@ -24,7 +24,7 @@ int main(int argc, char **argv) sha1_dir = getenv(DB_ENVIRONMENT); if (sha1_dir) { struct stat st; - if (!stat(sha1_dir, &st) < 0 && S_ISDIR(st.st_mode)) + if (!stat(sha1_dir, &st) && S_ISDIR(st.st_mode)) return 0; fprintf(stderr, "DB_ENVIRONMENT set to bad directory %s: ", sha1_dir); } -- 2.30.2