[arch-commits] Commit in grpc/trunk (PKGBUILD python-grpcio-nullptr-fix.patch)
Konstantin Gizdov
kgizdov at gemini.archlinux.org
Thu Apr 21 08:50:03 UTC 2022
Date: Thursday, April 21, 2022 @ 08:50:02
Author: kgizdov
Revision: 1187213
apply patch to fix nullptr deref in python-grpcio
Added:
grpc/trunk/python-grpcio-nullptr-fix.patch
Modified:
grpc/trunk/PKGBUILD
---------------------------------+
PKGBUILD | 9 +++++--
python-grpcio-nullptr-fix.patch | 45 ++++++++++++++++++++++++++++++++++++++
2 files changed, 51 insertions(+), 3 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2022-04-21 08:45:18 UTC (rev 1187212)
+++ PKGBUILD 2022-04-21 08:50:02 UTC (rev 1187213)
@@ -6,7 +6,7 @@
pkgname=('grpc' 'python-grpcio' 'php-grpc' 'php7-grpc' 'grpc-cli')
pkgver=1.45.2
_gtestver=0e402173c97aea7a00749e825b194bfede4f2e45
-pkgrel=1
+pkgrel=2
pkgdesc="High performance, open source, general RPC framework that puts mobile and HTTP/2 first."
arch=('x86_64')
url='https://grpc.io'
@@ -17,14 +17,17 @@
checkdepends=('python-six')
source=("https://github.com/grpc/grpc/archive/v$pkgver/$pkgbase-$pkgver.tar.gz"
"https://github.com/google/googletest/archive/$_gtestver/googletest-$_gtestver.tar.gz"
- "python-grpcio-use-system-abseil.patch")
+ "python-grpcio-use-system-abseil.patch"
+ "python-grpcio-nullptr-fix.patch")
sha256sums=('e18b16f7976aab9a36c14c38180f042bb0fd196b75c9fd6a20a2b5f934876ad6'
'c8de6c60e12ad014a28225c5247ee735861d85cf906df617f6a29954ca05f547'
- '3cfb289266f9d2697b917e4400f18a6592f95a99e658e401c1332870b219358b')
+ '3cfb289266f9d2697b917e4400f18a6592f95a99e658e401c1332870b219358b'
+ '3d3364a9cd71aae95f683242c7022f6599880b8d6df2472efab755820b2c0f21')
prepare() {
cd "$srcdir/$pkgbase-$pkgver"
patch -Np1 -i ../python-grpcio-use-system-abseil.patch
+ patch -Np1 -i ../python-grpcio-nullptr-fix.patch
ln -sf "$srcdir/googletest-$_gtestver/"{googlemock,googletest} \
third_party/googletest
Added: python-grpcio-nullptr-fix.patch
===================================================================
--- python-grpcio-nullptr-fix.patch (rev 0)
+++ python-grpcio-nullptr-fix.patch 2022-04-21 08:50:02 UTC (rev 1187213)
@@ -0,0 +1,45 @@
+From 05af494b282542304c9fa60d19e8aa1b9f474621 Mon Sep 17 00:00:00 2001
+From: Esun Kim <veblush at google.com>
+Date: Thu, 7 Apr 2022 21:16:30 -0700
+Subject: [PATCH] Fix bugprone-stringview-nullptr (#29346)
+
+---
+ src/core/lib/http/httpcli_security_connector.cc | 2 +-
+ .../security_connector/local/local_security_connector.cc | 4 ++--
+ 2 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/src/core/lib/http/httpcli_security_connector.cc b/src/core/lib/http/httpcli_security_connector.cc
+index 9f2c5249bb61..99273173e715 100644
+--- a/src/core/lib/http/httpcli_security_connector.cc
++++ b/src/core/lib/http/httpcli_security_connector.cc
+@@ -48,7 +48,7 @@ class grpc_httpcli_ssl_channel_security_connector final
+ public:
+ explicit grpc_httpcli_ssl_channel_security_connector(char* secure_peer_name)
+ : grpc_channel_security_connector(
+- /*url_scheme=*/nullptr,
++ /*url_scheme=*/{},
+ /*channel_creds=*/nullptr,
+ /*request_metadata_creds=*/nullptr),
+ secure_peer_name_(secure_peer_name) {}
+diff --git a/src/core/lib/security/security_connector/local/local_security_connector.cc b/src/core/lib/security/security_connector/local/local_security_connector.cc
+index 952189868fe2..f97299d03c0f 100644
+--- a/src/core/lib/security/security_connector/local/local_security_connector.cc
++++ b/src/core/lib/security/security_connector/local/local_security_connector.cc
+@@ -152,7 +152,7 @@ class grpc_local_channel_security_connector final
+ grpc_core::RefCountedPtr<grpc_channel_credentials> channel_creds,
+ grpc_core::RefCountedPtr<grpc_call_credentials> request_metadata_creds,
+ const char* target_name)
+- : grpc_channel_security_connector(nullptr, std::move(channel_creds),
++ : grpc_channel_security_connector({}, std::move(channel_creds),
+ std::move(request_metadata_creds)),
+ target_name_(gpr_strdup(target_name)) {}
+
+@@ -210,7 +210,7 @@ class grpc_local_server_security_connector final
+ public:
+ explicit grpc_local_server_security_connector(
+ grpc_core::RefCountedPtr<grpc_server_credentials> server_creds)
+- : grpc_server_security_connector(nullptr, std::move(server_creds)) {}
++ : grpc_server_security_connector({}, std::move(server_creds)) {}
+ ~grpc_local_server_security_connector() override = default;
+
+ void add_handshakers(
More information about the arch-commits
mailing list