Hi Sergei,

On Thu, 2023-12-21 at 09:23 +0000, Sergei Trofimovich wrote:
> `gcc-14` added a new `-Wcalloc-transposed-args` warning recently. It
> detected minor infelicity in `calloc()` API usage in `elfutils`:
> 
>     elfstrmerge.c: In function 'main':
>     elfstrmerge.c:450:32: error:
>       'calloc' sizes specified with 'sizeof' in the earlier argument and not 
> in the later argument [-Werror=calloc-transposed-args]
>       450 |   newscnbufs = calloc (sizeof (void *), newshnums);
>           |                                ^~~~
>     elfstrmerge.c:450:32: note: earlier argument should specify number of 
> elements, later size of each element
> 

Thanks, looks good. Pushed.

Cheers,

Mark

Reply via email to