summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 22bac0e)
raw | patch | inline | side by side (parent: 22bac0e)
author | Junio C Hamano <junkio@cox.net> | |
Sun, 7 Jan 2007 08:11:11 +0000 (00:11 -0800) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Sun, 7 Jan 2007 08:11:11 +0000 (00:11 -0800) |
This is shorter and easier to read, and also makes sure the
constant expression does not overflow integer range.
Signed-off-by: Junio C Hamano <junkio@cox.net>
constant expression does not overflow integer range.
Signed-off-by: Junio C Hamano <junkio@cox.net>
git-compat-util.h | patch | blob | history |
diff --git a/git-compat-util.h b/git-compat-util.h
index 55456da37cdd25126b7bccae879ca500176220f9..e023bf141363d87abfef358134e484ea85f32a15 100644 (file)
--- a/git-compat-util.h
+++ b/git-compat-util.h
#endif /* NO_MMAP */
#define DEFAULT_PACKED_GIT_LIMIT \
- (sizeof(void*) >= 8 \
- ? 8 * 1024 * 1024 * 1024 \
- : 256 * 1024 * 1024)
+ ((1024L * 1024L) * (sizeof(void*) >= 8 ? 8192 : 256))
#ifdef NO_SETENV
#define setenv gitsetenv