summaryrefslogtreecommitdiffstats
path: root/recipes-qt/qt5/qtwebengine/chromium/0025-chromium-musl-initialize-msghdr-in-a-compatible-mann.patch
diff options
context:
space:
mode:
authorJani Suonpera <jani.suonpera@qt.io>2021-01-27 09:21:29 +0200
committerJani Suonpera <jani.suonpera@qt.io>2021-02-05 14:56:55 +0200
commita73de388e628a67490cdd7734779d405740b7fa3 (patch)
treec6410cd0062df9dde1fd02b56232027b7f865815 /recipes-qt/qt5/qtwebengine/chromium/0025-chromium-musl-initialize-msghdr-in-a-compatible-mann.patch
parent7dfe6ec495c3e56e4fbfb1dba23291589c28f7a7 (diff)
downloadmeta-qt5-a73de388e628a67490cdd7734779d405740b7fa3.tar.gz
qt5: update submodules for LTS 5.15
- Webengine-chromium branch changed from 83-based to 87-based. - PACKAGECONFIGs protobuf and jsoncpp are removed because these configurations has been removed from src/buildtools/configure.json - DEPENDS nodejs-native added. This mandatory for chromium build. Task-number: QTBUG-90623 Change-Id: Ic933c88399422941114915afe5baa202850928f4 Reviewed-by: Samuli Piippo <samuli.piippo@qt.io>
Diffstat (limited to 'recipes-qt/qt5/qtwebengine/chromium/0025-chromium-musl-initialize-msghdr-in-a-compatible-mann.patch')
-rw-r--r--recipes-qt/qt5/qtwebengine/chromium/0025-chromium-musl-initialize-msghdr-in-a-compatible-mann.patch45
1 files changed, 45 insertions, 0 deletions
diff --git a/recipes-qt/qt5/qtwebengine/chromium/0025-chromium-musl-initialize-msghdr-in-a-compatible-mann.patch b/recipes-qt/qt5/qtwebengine/chromium/0025-chromium-musl-initialize-msghdr-in-a-compatible-mann.patch
new file mode 100644
index 00000000..d2617a83
--- /dev/null
+++ b/recipes-qt/qt5/qtwebengine/chromium/0025-chromium-musl-initialize-msghdr-in-a-compatible-mann.patch
@@ -0,0 +1,45 @@
1From b37418977ba9bb13dae396b929f3365866e86af1 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Sun, 10 May 2020 08:16:01 -0700
4Subject: [PATCH] chromium: musl: initialize msghdr in a compatible manner
5
6initialize msghdr in a compatible manner
7
8msghdr stuct from socket.h is not same between musl and glibc
9where musl claims to be more posix compliant where as glibc seems
10to fill whats needed for linux sizewise and chooses long enough types
11which maybe questionable, therefore constructing a structure with explicit
12constructor is not going to work correctly for musl and glibc at same time
13
14see
15https://git.musl-libc.org/cgit/musl/commit/arch/x86_64/bits/socket.h?id=7168790763cdeb794df52be6e3b39fbb021c5a64
16
17This fix initialized the struct to 0 first and then sets the struct elements
18by name, so we dont have to hard code the positions of elements when initializing
19structure
20
21Upstream-Status: Pending
22Signed-off-by: Khem Raj <raj.khem@gmail.com>
23---
24 chromium/net/socket/udp_socket_posix.cc | 8 ++++++--
25 1 file changed, 6 insertions(+), 2 deletions(-)
26
27diff --git a/chromium/net/socket/udp_socket_posix.cc b/chromium/net/socket/udp_socket_posix.cc
28index 71265568be5..42e0d298045 100644
29--- a/chromium/net/socket/udp_socket_posix.cc
30+++ b/chromium/net/socket/udp_socket_posix.cc
31@@ -1151,8 +1151,12 @@ SendResult UDPSocketPosixSender::InternalSendmmsgBuffers(
32 for (auto& buffer : buffers)
33 msg_iov->push_back({const_cast<char*>(buffer->data()), buffer->length()});
34 msgvec->reserve(buffers.size());
35- for (size_t j = 0; j < buffers.size(); j++)
36- msgvec->push_back({{nullptr, 0, &msg_iov[j], 1, nullptr, 0, 0}, 0});
37+ for (size_t j = 0; j < buffers.size(); j++) {
38+ struct msghdr m = {0};
39+ m.msg_iov = &msg_iov[j];
40+ m.msg_iovlen = 1;
41+ msgvec->push_back({m, 0});
42+ }
43 int result = HANDLE_EINTR(Sendmmsg(fd, &msgvec[0], buffers.size(), 0));
44 SendResult send_result(0, 0, std::move(buffers));
45 if (result < 0) {