Get the right patch this time.
Disable pointer-comparison warning for StackLowerThanAddress
This commit is contained in:
parent
347f98af2c
commit
2f2fa40ea7
15
gtest-gcc11.patch
Normal file
15
gtest-gcc11.patch
Normal file
@ -0,0 +1,15 @@
|
||||
diff --git a/googletest/src/gtest-death-test.cc b/googletest/src/gtest-death-test.cc
|
||||
index da09a1c..4d6343f 100644
|
||||
--- a/googletest/src/gtest-death-test.cc
|
||||
+++ b/googletest/src/gtest-death-test.cc
|
||||
@@ -1289,7 +1289,10 @@ static void StackLowerThanAddress(const void* ptr,
|
||||
GTEST_ATTRIBUTE_NO_SANITIZE_HWADDRESS_
|
||||
static void StackLowerThanAddress(const void* ptr, bool* result) {
|
||||
int dummy;
|
||||
+#pragma GCC diagnostic push
|
||||
+#pragma GCC diagnostic ignored "-Wpointer-compare="
|
||||
*result = (&dummy < ptr);
|
||||
+#pragma GCC diagnostic push
|
||||
}
|
||||
|
||||
// Make sure AddressSanitizer does not tamper with the stack here.
|
||||
@ -112,7 +112,7 @@ sed -e "s/set(GOOGLETEST_VERSION .*)/set(GOOGLETEST_VERSION %{version})/" -i CMa
|
||||
|
||||
%changelog
|
||||
* Sun Nov 15 2020 Jeff Law <law@redhat.com> - 1.10.0-4
|
||||
- Fix argument type for StackLowerThanAddress to silence fatal gcc-11 diagnostic
|
||||
- Disable pointer-comparison warning in StackLowerThanAddress
|
||||
|
||||
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.10.0-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||
|
||||
Loading…
Reference in New Issue
Block a user