From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: net-libs/ngtcp2/, net-libs/ngtcp2/files/
Date: Fri, 03 Jan 2025 11:32:31 +0000 (UTC) [thread overview]
Message-ID: <1735903865.7caf564409af2b3a5cd3df3ed0feb65c7fc061e3.sam@gentoo> (raw)
commit: 7caf564409af2b3a5cd3df3ed0feb65c7fc061e3
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Jan 3 11:30:38 2025 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Jan 3 11:31:05 2025 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7caf5644
net-libs/ngtcp2: fix uninitialised variables
Backport upstream fixes (thank you!) for uninitialised variables exposed
by GCC 15's padding changes.
Closes: https://bugs.gentoo.org/947300
Signed-off-by: Sam James <sam <AT> gentoo.org>
.../ngtcp2/files/ngtcp2-1.10.0-gcc15-uninit.patch | 46 +++++++++++++++++
net-libs/ngtcp2/ngtcp2-1.10.0-r2.ebuild | 60 ++++++++++++++++++++++
2 files changed, 106 insertions(+)
diff --git a/net-libs/ngtcp2/files/ngtcp2-1.10.0-gcc15-uninit.patch b/net-libs/ngtcp2/files/ngtcp2-1.10.0-gcc15-uninit.patch
new file mode 100644
index 000000000000..7ce0cf2b6c3c
--- /dev/null
+++ b/net-libs/ngtcp2/files/ngtcp2-1.10.0-gcc15-uninit.patch
@@ -0,0 +1,46 @@
+https://bugs.gentoo.org/947300
+https://github.com/ngtcp2/ngtcp2/pull/1464
+https://github.com/ngtcp2/ngtcp2/commit/60ab2b73aa02e6c99597b975724c6b58008c4869
+https://github.com/ngtcp2/ngtcp2/commit/416698347d60968eba635182dfdedc44d1aa7c3b
+
+From 60ab2b73aa02e6c99597b975724c6b58008c4869 Mon Sep 17 00:00:00 2001
+From: Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>
+Date: Fri, 3 Jan 2025 10:05:55 +0900
+Subject: [PATCH] tests: Fix uninitialized variable reference
+
+--- a/tests/ngtcp2_transport_params_test.c
++++ b/tests/ngtcp2_transport_params_test.c
+@@ -419,11 +419,16 @@ void test_ngtcp2_transport_params_convert_to_latest(void) {
+ ngtcp2_cid rcid, scid, dcid;
+ uint8_t available_versions[sizeof(uint32_t) * 3];
+ ngtcp2_sockaddr_in6 *sa_in6;
++ size_t i;
+
+ rcid_init(&rcid);
+ scid_init(&scid);
+ dcid_init(&dcid);
+
++ for (i = 0; i < sizeof(available_versions); i += sizeof(uint32_t)) {
++ ngtcp2_put_uint32be(&available_versions[i], (uint32_t)(0xff000000u + i));
++ }
++
+ ngtcp2_transport_params_default_versioned(NGTCP2_TRANSPORT_PARAMS_V1,
+ &srcbuf);
+
+
+From 416698347d60968eba635182dfdedc44d1aa7c3b Mon Sep 17 00:00:00 2001
+From: Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>
+Date: Fri, 3 Jan 2025 10:13:56 +0900
+Subject: [PATCH] Fix uninitialized connection close frame_type
+
+--- a/lib/ngtcp2_conn.c
++++ b/lib/ngtcp2_conn.c
+@@ -13765,6 +13765,7 @@ ngtcp2_ssize ngtcp2_pkt_write_connection_close(
+
+ fr.type = NGTCP2_FRAME_CONNECTION_CLOSE;
+ fr.connection_close.error_code = error_code;
++ fr.connection_close.frame_type = 0;
+ fr.connection_close.reasonlen = reasonlen;
+ fr.connection_close.reason = (uint8_t *)reason;
+
+
diff --git a/net-libs/ngtcp2/ngtcp2-1.10.0-r2.ebuild b/net-libs/ngtcp2/ngtcp2-1.10.0-r2.ebuild
new file mode 100644
index 000000000000..b88f76b1fbc3
--- /dev/null
+++ b/net-libs/ngtcp2/ngtcp2-1.10.0-r2.ebuild
@@ -0,0 +1,60 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake-multilib
+
+if [[ ${PV} == 9999 ]] ; then
+ EGIT_REPO_URI="https://github.com/ngtcp2/ngtcp2.git"
+ inherit git-r3
+else
+ SRC_URI="https://github.com/ngtcp2/ngtcp2/releases/download/v${PV}/${P}.tar.xz"
+ KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86"
+fi
+
+DESCRIPTION="Implementation of the IETF QUIC Protocol"
+HOMEPAGE="https://github.com/ngtcp2/ngtcp2/"
+
+LICENSE="MIT"
+SLOT="0/0"
+IUSE="+gnutls openssl +ssl static-libs test"
+# Without static-libs, src_test just won't run any tests and "pass".
+REQUIRED_USE="ssl? ( || ( gnutls openssl ) ) test? ( static-libs )"
+
+BDEPEND="virtual/pkgconfig"
+RDEPEND="
+ ssl? (
+ gnutls? ( >=net-libs/gnutls-3.7.2:=[${MULTILIB_USEDEP}] )
+ openssl? ( >=dev-libs/openssl-1.1.1:=[${MULTILIB_USEDEP}] )
+ )
+"
+DEPEND="
+ ${RDEPEND}
+ test? ( >=dev-util/cunit-2.1[${MULTILIB_USEDEP}] )
+"
+RESTRICT="!test? ( test )"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-1.10.0-munit-c23.patch
+ "${FILESDIR}"/${P}-gcc15-uninit.patch
+)
+
+multilib_src_configure() {
+ local mycmakeargs=(
+ -DENABLE_STATIC_LIB=$(usex static-libs)
+ -DENABLE_GNUTLS=$(usex gnutls)
+ -DENABLE_OPENSSL=$(usex openssl)
+ -DENABLE_BORINGSSL=OFF
+ -DENABLE_PICOTLS=OFF
+ -DENABLE_WOLFSSL=OFF
+ -DCMAKE_DISABLE_FIND_PACKAGE_Libev=ON
+ -DCMAKE_DISABLE_FIND_PACKAGE_Libnghttp3=ON
+ -DBUILD_TESTING=$(usex test)
+ )
+ cmake_src_configure
+}
+
+multilib_src_test() {
+ cmake_build check
+}
next reply other threads:[~2025-01-03 11:32 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-03 11:32 Sam James [this message]
-- strict thread matches above, loose matches on Subject: below --
2025-01-01 8:02 [gentoo-commits] repo/gentoo:master commit in: net-libs/ngtcp2/, net-libs/ngtcp2/files/ Sam James
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1735903865.7caf564409af2b3a5cd3df3ed0feb65c7fc061e3.sam@gentoo \
--to=sam@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox