diff options
| author | Jafar Al-Gharaibeh <jafar@atcorp.com> | 2024-09-30 12:42:12 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-09-30 12:42:12 -0500 |
| commit | 237152fcb5870f021013b3be9eda59190cd81755 (patch) | |
| tree | 59bfa76575a8ef77a70da1218b1c062589a341e4 | |
| parent | a8482dbe6eae96c917329baa410b3947820bf551 (diff) | |
| parent | 660146b57ad48f40ca4ea845cc8538500a8d4759 (diff) | |
Merge pull request #16958 from opensourcerouting/calloc-warning-fix
lib: fix calloc warning on recent compiler
| -rw-r--r-- | lib/elf_py.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/elf_py.c b/lib/elf_py.c index 2b4fea373f..6c63d1f892 100644 --- a/lib/elf_py.c +++ b/lib/elf_py.c @@ -1307,7 +1307,7 @@ static PyObject *elffile_load(PyTypeObject *type, PyObject *args, } #endif - w->sects = calloc(sizeof(PyObject *), w->ehdr->e_shnum); + w->sects = calloc(w->ehdr->e_shnum, sizeof(PyObject *)); w->n_sect = w->ehdr->e_shnum; return (PyObject *)w; |
