diff options
| author | Junio C Hamano <gitster@pobox.com> | 2025-12-13 10:39:23 +0900 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2025-12-13 10:39:23 +0900 |
| commit | 6362c9ce5eb18f699affbb2a7b357cb9b469105c (patch) | |
| tree | 49ca64dd03d243c58c1ce3fb8d68db9dabd5b7a5 /diff-delta.c | |
| parent | 2a04e8c293766a4976ceceb4c663dd2963e0339e (diff) | |
| parent | 467860bc0b0447093ae97bcecf1655131732338f (diff) | |
| download | git-6362c9ce5eb18f699affbb2a7b357cb9b469105c.tar.xz | |
Merge branch 'tc/memzero-array' into jc/memzero-array
* tc/memzero-array:
contrib/coccinelle: pass include paths to spatch(1)
git-compat-util: introduce MEMZERO_ARRAY() macro
last-modified: fix use of uninitialized memory
Diffstat (limited to 'diff-delta.c')
| -rw-r--r-- | diff-delta.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/diff-delta.c b/diff-delta.c index 71d37368d6..43c339f010 100644 --- a/diff-delta.c +++ b/diff-delta.c @@ -171,7 +171,7 @@ struct delta_index * create_delta_index(const void *buf, unsigned long bufsize) mem = hash + hsize; entry = mem; - memset(hash, 0, hsize * sizeof(*hash)); + MEMZERO_ARRAY(hash, hsize); /* allocate an array to count hash entries */ hash_count = calloc(hsize, sizeof(*hash_count)); |
