summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Varga <pvarga@inf.u-szeged.hu>2022-03-04 10:42:25 +0100
committerPeter Varga <pvarga@inf.u-szeged.hu>2022-03-04 12:06:26 +0000
commit107ed30ec505f20f166cf7df3b99c5c73a680796 (patch)
tree66a5f1af5a4152eca853acc1b7a705ecf0da20f9
parentb23d336c9aa1d613a7011d754c857cee86a0b7fa (diff)
downloadqtwebengine-chromium-107ed30ec505f20f166cf7df3b99c5c73a680796.tar.gz
[Backport] Fix for non-constant SIGSTKSZ
On glibc > 2.33, `SIGSTKSZ` might not be constant (in which case it expands to a call to `sysconf` which returns a `long int`); see https://sourceware.org/pipermail/libc-alpha/2020-October/118513.html Pass unsigned explicitly to std::max, to avoid relying on template argument deduction. This works both with the old-style constant `SIGSTKSZ` and the new configurable one. Initially based on https://chromium-review.googlesource.com/c/2776379 Change-Id: I2279e8423aa70987ce4537674c7291216d23062f Review-URL: https://chromium-review.googlesource.com/c/breakpad/breakpad/+/3340721 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
-rw-r--r--chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc b/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
index ca353c40997..4c73053c513 100644
--- a/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
+++ b/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
@@ -138,7 +138,7 @@ void InstallAlternateStackLocked() {
// SIGSTKSZ may be too small to prevent the signal handlers from overrunning
// the alternative stack. Ensure that the size of the alternative stack is
// large enough.
- static const unsigned kSigStackSize = std::max(16384, SIGSTKSZ);
+ static const unsigned kSigStackSize = std::max<unsigned>(16384, SIGSTKSZ);
// Only set an alternative stack if there isn't already one, or if the current
// one is too small.