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

Does not compile on GCC13 #2907

Closed
tomzdotorg opened this issue Jun 13, 2023 · 3 comments
Closed

Does not compile on GCC13 #2907

tomzdotorg opened this issue Jun 13, 2023 · 3 comments

Comments

@tomzdotorg
Copy link

Due to -Werror and new GCC13 enum-int-mismatch warning

e.g.
./lib/tls/openssl/openssl-server.c:713:1: error: conflicting types for ‘lws_tls_server_abort_connection’ due to enum/integer mismatch; have ‘int(struct lws *)’ [-Werror=enum-int-mismatch]

Potential fix: Change the return type of function lws_ssl_capable_status from int to enum lws_ssl_capable_status

@lws-team
Copy link
Member

Hm on main branch it has been like that since 89cb55e in 2017, 6 years ago, which means any halfway recent release is all like that too.

Just update to a recent release like v4.3.

@tomzdotorg
Copy link
Author

I was using 4.3.2, and the problem is indeed there (note there is a copy-paste typo in my original post, the function name is lws_tls_server_abort_connection)

e.g. here
libwebsockets-4.3.2/lib/tls/openssl/openssl-server.c

int lws_tls_server_abort_connection(struct lws *wsi)`

and a similar conditional definition in
libwebsockets-4.3.2/lib/tls/mbedtls/mbedtls-server.c

@lws-team
Copy link
Member

OK it got a bit confused one way and another. 713 on main happens to be one line below the return type that is involved in your problem and looked like what you're talking about.

I took the approach to build it in f38 and got your actual problem. I fixed that and pushed on main and v4.3-stable.

algitbot pushed a commit to alpinelinux/aports that referenced this issue Oct 17, 2023
bell-sw pushed a commit to bell-sw/alpaquita-aports that referenced this issue Oct 20, 2023
[ commit 0a09bc3f16e0a965c963d90011b4088237b01942 ]

ref: warmcat/libwebsockets#2907
upstream: warmcat/libwebsockets@f9d1f25

We already have this patch, here we align our version with Alpine.
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

No branches or pull requests

2 participants