git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] trivial fix for init-db
@ 2005-04-18 23:14 Aaron Straus
  0 siblings, 0 replies; only message in thread
From: Aaron Straus @ 2005-04-18 23:14 UTC (permalink / raw)
  To: git

This makes init-db work for common object database.

Signed-Off-By: Aaron Straus <aaron@merfinllc.com>

init-db.c: aa00fbb1b95624f6c30090a17354c9c08a6ac596
--- 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);
 	}

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2005-04-18 23:14 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-04-18 23:14 [PATCH] trivial fix for init-db Aaron Straus

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).