Failure to build with GCC 14
Closed this issue · 1 comments
dvdesolve commented
Seems like GCC 14 doesn't like transposed arguments in calloc
, so I've catched at least two errors during build:
net_io.c: In function ‘serviceInit’:
net_io.c:107:34: error: ‘calloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument [-Werror=calloc-transposed-args]
107 | if (!(service = calloc(sizeof(*service), 1))) {
| ^
net_io.c:107:34: note: earlier argument should specify number of elements, later size of each element
adaptive.c: In function ‘adaptive_init’:
adaptive.c:198:42: error: ‘calloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument [-Werror=calloc-transposed-args]
198 | adaptive_range_radix = calloc(sizeof(unsigned), 65536);
| ^~~~~~~~
adaptive.c:198:42: note: earlier argument should specify number of elements, later size of each element
mutability commented
#239 fixes this