* [Buildroot] [PATCH 1/1] package/libcddb: Fix build with gcc-14
@ 2025-07-06 10:10 Bernd Kuhls
2025-07-06 10:42 ` David Laight
0 siblings, 1 reply; 2+ messages in thread
From: Bernd Kuhls @ 2025-07-06 10:10 UTC (permalink / raw)
To: buildroot; +Cc: Julien Boibessot
Fixes:
https://autobuild.buildroot.net/results/723/7236cf5fd4f33aabd3178586f877dff04d754abe/
Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
---
package/libcddb/0001-gcc14.patch | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
create mode 100644 package/libcddb/0001-gcc14.patch
diff --git a/package/libcddb/0001-gcc14.patch b/package/libcddb/0001-gcc14.patch
new file mode 100644
index 0000000000..fe06d2512d
--- /dev/null
+++ b/package/libcddb/0001-gcc14.patch
@@ -0,0 +1,24 @@
+Fix build with gcc-14
+
+https://bugs.gentoo.org/919280
+https://src.fedoraproject.org/rpms/libcddb/blob/rawhide/f/pointer-types.patch
+
+Patch downloaded from
+https://gitweb.gentoo.org/repo/gentoo.git/tree/media-libs/libcddb/files/libcddb-1.3.2-c99.patch?id=9200fde5b926191737a8380a08cffa2998013945
+
+Upstream: https://sourceforge.net/p/libcddb/patches/9/
+
+Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
+
+--- a/lib/cddb_net.c
++++ b/lib/cddb_net.c
+@@ -329,7 +329,7 @@
+ default:
+ /* we got connected, check error condition */
+ l = sizeof(rv);
+- getsockopt(sockfd, SOL_SOCKET, SO_ERROR, &rv, &l);
++ getsockopt(sockfd, SOL_SOCKET, SO_ERROR, &rv, (socklen_t * restrict)&l);
+ if (rv) {
+ /* something went wrong, simulate normal connect behaviour */
+ errno = rv;
+
--
2.39.5
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Buildroot] [PATCH 1/1] package/libcddb: Fix build with gcc-14
2025-07-06 10:10 [Buildroot] [PATCH 1/1] package/libcddb: Fix build with gcc-14 Bernd Kuhls
@ 2025-07-06 10:42 ` David Laight
0 siblings, 0 replies; 2+ messages in thread
From: David Laight @ 2025-07-06 10:42 UTC (permalink / raw)
To: Bernd Kuhls; +Cc: buildroot, Julien Boibessot
On Sun, 6 Jul 2025 12:10:44 +0200
Bernd Kuhls <bernd@kuhls.net> wrote:
> Fixes:
> https://autobuild.buildroot.net/results/723/7236cf5fd4f33aabd3178586f877dff04d754abe/
>
> Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
> ---
> package/libcddb/0001-gcc14.patch | 24 ++++++++++++++++++++++++
> 1 file changed, 24 insertions(+)
> create mode 100644 package/libcddb/0001-gcc14.patch
>
> diff --git a/package/libcddb/0001-gcc14.patch b/package/libcddb/0001-gcc14.patch
> new file mode 100644
> index 0000000000..fe06d2512d
> --- /dev/null
> +++ b/package/libcddb/0001-gcc14.patch
> @@ -0,0 +1,24 @@
> +Fix build with gcc-14
> +
> +https://bugs.gentoo.org/919280
> +https://src.fedoraproject.org/rpms/libcddb/blob/rawhide/f/pointer-types.patch
> +
> +Patch downloaded from
> +https://gitweb.gentoo.org/repo/gentoo.git/tree/media-libs/libcddb/files/libcddb-1.3.2-c99.patch?id=9200fde5b926191737a8380a08cffa2998013945
> +
> +Upstream: https://sourceforge.net/p/libcddb/patches/9/
> +
> +Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
> +
> +--- a/lib/cddb_net.c
> ++++ b/lib/cddb_net.c
> +@@ -329,7 +329,7 @@
> + default:
> + /* we got connected, check error condition */
> + l = sizeof(rv);
> +- getsockopt(sockfd, SOL_SOCKET, SO_ERROR, &rv, &l);
> ++ getsockopt(sockfd, SOL_SOCKET, SO_ERROR, &rv, (socklen_t * restrict)&l);
That can't really be right.
You need to change the type of 'l' to be the same as socklen_t.
If the sizes of the integer types differ then you've either passes the
wrong value (typical for big endian) or corrupted stack.
David
> + if (rv) {
> + /* something went wrong, simulate normal connect behaviour */
> + errno = rv;
> +
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2025-07-06 10:42 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-06 10:10 [Buildroot] [PATCH 1/1] package/libcddb: Fix build with gcc-14 Bernd Kuhls
2025-07-06 10:42 ` David Laight
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.