Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failure to build with GCC 14 #241

Closed
dvdesolve opened this issue Jun 3, 2024 · 1 comment
Closed

Failure to build with GCC 14 #241

dvdesolve opened this issue Jun 3, 2024 · 1 comment

Comments

@dvdesolve
Copy link

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
bovine added a commit that referenced this issue Jun 18, 2024
@mutability
Copy link

#239 fixes this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants