summaryrefslogtreecommitdiffstats
path: root/build/build-clang/win64-ret-null-on-commitment-limit_clang_14.patch
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:47:29 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:47:29 +0000
commit0ebf5bdf043a27fd3dfb7f92e0cb63d88954c44d (patch)
treea31f07c9bcca9d56ce61e9a1ffd30ef350d513aa /build/build-clang/win64-ret-null-on-commitment-limit_clang_14.patch
parentInitial commit. (diff)
downloadfirefox-esr-37a0381f8351b370577b65028ba1f6563ae23fdf.tar.xz
firefox-esr-37a0381f8351b370577b65028ba1f6563ae23fdf.zip
Adding upstream version 115.8.0esr.upstream/115.8.0esr
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'build/build-clang/win64-ret-null-on-commitment-limit_clang_14.patch')
-rw-r--r--build/build-clang/win64-ret-null-on-commitment-limit_clang_14.patch14
1 files changed, 14 insertions, 0 deletions
diff --git a/build/build-clang/win64-ret-null-on-commitment-limit_clang_14.patch b/build/build-clang/win64-ret-null-on-commitment-limit_clang_14.patch
new file mode 100644
index 0000000000..23b001bc68
--- /dev/null
+++ b/build/build-clang/win64-ret-null-on-commitment-limit_clang_14.patch
@@ -0,0 +1,14 @@
+diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_win.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_win.cpp
+index 7c84cdc22ce4..e13fff03489e 100644
+--- a/compiler-rt/lib/sanitizer_common/sanitizer_win.cpp
++++ b/compiler-rt/lib/sanitizer_common/sanitizer_win.cpp
+@@ -157,7 +157,8 @@ void UnmapOrDie(void *addr, uptr size) {
+ static void *ReturnNullptrOnOOMOrDie(uptr size, const char *mem_type,
+ const char *mmap_type) {
+ error_t last_error = GetLastError();
+- if (last_error == ERROR_NOT_ENOUGH_MEMORY)
++ if (last_error == ERROR_NOT_ENOUGH_MEMORY ||
++ last_error == ERROR_COMMITMENT_LIMIT)
+ return nullptr;
+ ReportMmapFailureAndDie(size, mem_type, mmap_type, last_error);
+ }