diff mbox series

[meta-networking,7/20] ngtcp2: upgrade 1.25.0 -> 1.26.0

Message ID 20261103183640.919438-7-ankur.tyagi85@gmail.com
State Under Review
Headers show
Series [meta-multimedia,1/20] libopenmpt: upgrade 0.8.9 -> 0.8.10 | expand

Commit Message

Ankur Tyagi Nov. 3, 2026, 6:36 p.m. UTC
From: Ankur Tyagi <ankur.tyagi85@gmail.com>

Dropped patch that is part of the upstream version.

Changelog:
https://github.com/ngtcp2/ngtcp2/releases/tag/v1.26.0

Signed-off-by: Ankur Tyagi <ankur.tyagi85@gmail.com>
---
 ...Do-not-truncate-file-sizes-on-32-bit.patch | 63 -------------------
 .../{ngtcp2_1.25.0.bb => ngtcp2_1.26.0.bb}    |  3 +-
 2 files changed, 1 insertion(+), 65 deletions(-)
 delete mode 100644 meta-networking/recipes-protocols/ngtcp2/ngtcp2/0001-examples-server-Do-not-truncate-file-sizes-on-32-bit.patch
 rename meta-networking/recipes-protocols/ngtcp2/{ngtcp2_1.25.0.bb => ngtcp2_1.26.0.bb} (86%)
diff mbox series

Patch

diff --git a/meta-networking/recipes-protocols/ngtcp2/ngtcp2/0001-examples-server-Do-not-truncate-file-sizes-on-32-bit.patch b/meta-networking/recipes-protocols/ngtcp2/ngtcp2/0001-examples-server-Do-not-truncate-file-sizes-on-32-bit.patch
deleted file mode 100644
index 746663dc20..0000000000
--- a/meta-networking/recipes-protocols/ngtcp2/ngtcp2/0001-examples-server-Do-not-truncate-file-sizes-on-32-bit.patch
+++ /dev/null
@@ -1,63 +0,0 @@ 
-From: Khem Raj <khem.raj@oss.qualcomm.com>
-Date: Wed, 21 Oct 2026 09:00:00 -0700
-Subject: [PATCH] examples/server: Do not truncate file sizes on 32-bit
- targets
-
-FileEntry::len is a uint64_t, but it is used for mmap() and as the size
-of the resp_data std::span, both of which take a size_t. On targets
-where size_t is 32 bits, such as riscv32, clang rejects the narrowing in
-the span initializer:
-
-  examples/server.cc:236:54: error: non-constant-expression cannot be
-  narrowed from type 'uint64_t' (aka 'unsigned long long') to
-  'size_type' (aka 'unsigned int') in initializer list [-Wc++11-narrowing]
-
-The value is already truncated earlier, where st_size is cast to size_t
-before mmap(), so a file larger than the address space would be served
-with the wrong length.
-
-Store the length as a size_t, and fail open_file() with
-Error::INTEGER_OVERFLOW when the file is too large to map, instead of
-truncating its size.
-
-Upstream-Status: Submitted [https://github.com/ngtcp2/ngtcp2/pull/2330]
-Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
----
- examples/server.cc | 7 +++++++
- examples/server.h  | 2 +-
- 2 files changed, 8 insertions(+), 1 deletion(-)
-
---- a/examples/server.cc
-+++ b/examples/server.cc
-@@ -31,6 +31,8 @@
- #include <memory>
- #include <fstream>
- #include <iomanip>
-+#include <limits>
-+#include <utility>
- 
- #include <unistd.h>
- #include <getopt.h>
-@@ -216,6 +218,11 @@
-     close(fd);
-   } else {
-     fe.fd = fd;
-+    // A file larger than the address space cannot be mapped.
-+    if (std::cmp_greater(st.st_size, std::numeric_limits<size_t>::max())) {
-+      close(fd);
-+      return std::unexpected{Error::INTEGER_OVERFLOW};
-+    }
-     fe.len = static_cast<size_t>(st.st_size);
-     if (fe.len) {
-       fe.map = mmap(nullptr, fe.len, PROT_READ, MAP_SHARED, fd, 0);
---- a/examples/server.h
-+++ b/examples/server.h
-@@ -68,7 +68,7 @@
- };
- 
- struct FileEntry {
--  uint64_t len{};
-+  size_t len{};
-   void *map{};
-   int fd{};
-   uint8_t flags{};
diff --git a/meta-networking/recipes-protocols/ngtcp2/ngtcp2_1.25.0.bb b/meta-networking/recipes-protocols/ngtcp2/ngtcp2_1.26.0.bb
similarity index 86%
rename from meta-networking/recipes-protocols/ngtcp2/ngtcp2_1.25.0.bb
rename to meta-networking/recipes-protocols/ngtcp2/ngtcp2_1.26.0.bb
index a9d834a1b2..a11b510d10 100644
--- a/meta-networking/recipes-protocols/ngtcp2/ngtcp2_1.25.0.bb
+++ b/meta-networking/recipes-protocols/ngtcp2/ngtcp2_1.26.0.bb
@@ -5,9 +5,8 @@  LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://COPYING;md5=de0966c8ff4f62661a3da92967a75434"
 
 SRC_URI = "gitsm://github.com/ngtcp2/ngtcp2;protocol=https;branch=main;tag=v${PV} \
-           file://0001-examples-server-Do-not-truncate-file-sizes-on-32-bit.patch \
            "
-SRCREV = "f9e9ff01ad2c8116bc09de4f644b0028a61486a6"
+SRCREV = "6a22a4d7a111f6b52391910e40ad3681a09cfb9c"
 
 DEPENDS = "brotli libev nghttp3"