git.99rst.org
/
git.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
| inline |
side by side
(parent:
2ced105
)
ref_update_reject_duplicates(): use `size_t` rather than `int`
author
Michael Haggerty
<redacted>
Mon, 22 May 2017 14:17:46 +0000
(16:17 +0200)
committer
Junio C Hamano
<redacted>
Tue, 23 May 2017 05:29:55 +0000
(14:29 +0900)
Eliminate a theoretical risk of integer overflow if the two types have
different sizes.
Signed-off-by: Michael Haggerty <redacted>
Signed-off-by: Junio C Hamano <redacted>
refs.c
patch
|
blob
|
history
diff --git
a/refs.c
b/refs.c
index beb49fb2979fe7780e721237cc0e4d7c47c355ee..143936a9c3e5a5db1c41f9c8923c0f05cd99f365 100644
(file)
--- a/
refs.c
+++ b/
refs.c
@@
-1705,7
+1705,7
@@
int create_symref(const char *ref_target, const char *refs_heads_master,
int ref_update_reject_duplicates(struct string_list *refnames,
struct strbuf *err)
{
-
in
t i, n = refnames->nr;
+
size_
t i, n = refnames->nr;
assert(err);
git clone https://git.99rst.org/PROJECT