Page MenuHomeFreeBSD

elftoolchain: Consistently use item count as the first argument to calloc
ClosedPublic

Authored by jhb on Jul 17 2024, 7:16 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Nov 9, 12:07 PM
Unknown Object (File)
Sat, Nov 9, 12:07 PM
Unknown Object (File)
Sat, Nov 9, 12:07 PM
Unknown Object (File)
Wed, Nov 6, 9:32 PM
Unknown Object (File)
Wed, Nov 6, 7:39 PM
Unknown Object (File)
Wed, Nov 6, 6:35 AM
Unknown Object (File)
Tue, Oct 22, 9:03 AM
Unknown Object (File)
Oct 2 2024, 6:23 AM

Details

Summary

Reported by: GCC 14 -Wcalloc-transposed-args

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

emaste added a subscriber: jkoshy.

Will also ping @jkoshy

This revision is now accepted and ready to land.Jul 17 2024, 7:18 PM

Note that this was the only calloc instance in all of elftc that GCC warned about. All the others (even in this file) were already consistent with the number being first.

Hmm, I've been avoiding addressing warnings in contrib...

It's fine in elftoolchain - we are the primary consumer and either jkoshy or I can make the change upstream.