mirror of
https://github.com/opnsense/src.git
synced 2026-02-19 02:30:08 -05:00
bsdinstall: Consistently use item count as the first argument to calloc
Reported by: GCC 14 -Wcalloc-transposed-args Reviewed by: rlibby, imp, emaste Differential Revision: https://reviews.freebsd.org/D46012 (cherry picked from commit 7cd0a4c85dbe5e8cd000f6b293ef2d579d22edfb)
This commit is contained in:
parent
263483280c
commit
c28d88cda4
1 changed files with 2 additions and 2 deletions
|
|
@ -131,8 +131,8 @@ fetch_files(int nfiles, char **urls)
|
|||
struct bsddialog_conf mgconf;
|
||||
|
||||
/* Make the transfer list for mixedgauge */
|
||||
minilabel = calloc(sizeof(char *), nfiles);
|
||||
miniperc = calloc(sizeof(int), nfiles);
|
||||
minilabel = calloc(nfiles, sizeof(char *));
|
||||
miniperc = calloc(nfiles, sizeof(int));
|
||||
if (minilabel == NULL || miniperc == NULL)
|
||||
errx(EXIT_FAILURE, "Error: distfetch minibars out of memory!");
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue