Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
Merge branch 'rs/maint-config-use-labs' into maint
author
Junio C Hamano
<gitster@pobox.com>
Mon, 22 Dec 2014 20:17:23 +0000
(12:17 -0800)
committer
Junio C Hamano
<gitster@pobox.com>
Mon, 22 Dec 2014 20:17:23 +0000
(12:17 -0800)
* rs/maint-config-use-labs:
use labs() for variables of type long instead of abs()
config.c
patch
|
blob
|
history
raw
(from parent 1:
8390d5c
)
diff --git
a/config.c
b/config.c
index d5446d2b631e0bc13e78d12fed2c63b0e29aae0a..752e2e227f56edfb7b2ad168798c110c14a2c5e8 100644
(file)
--- a/
config.c
+++ b/
config.c
@@
-506,9
+506,9
@@
static int git_parse_signed(const char *value, intmax_t *ret, intmax_t max)
errno = EINVAL;
return 0;
}
- uval = abs(val);
+ uval =
l
abs(val);
uval *= factor;
- if (uval > max || abs(val) > uval) {
+ if (uval > max ||
l
abs(val) > uval) {
errno = ERANGE;
return 0;
}