Treat ERROR_WORKING_SET_QUOTA as OOM in ProcessBoundString
BUG=375332157 Change-Id: Ica0169cf1f2de2d22dad09de91ef5ec0dc8024ec Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5993937 Commit-Queue: Will Harris <wfh@chromium.org> Reviewed-by: Adam Langley <agl@chromium.org> Cr-Commit-Position: refs/heads/main@{#1379084}
This commit is contained in:

committed by
Chromium LUCI CQ

parent
9faa93a0df
commit
edb1694b10
@ -11,6 +11,8 @@
|
||||
#include <windows.h>
|
||||
|
||||
#include <dpapi.h>
|
||||
|
||||
#include "base/process/memory.h"
|
||||
#else
|
||||
#include "third_party/boringssl/src/include/openssl/mem.h"
|
||||
#endif // BUILDFLAG(IS_WIN)
|
||||
@ -49,6 +51,9 @@ bool MaybeDecryptBuffer(base::span<uint8_t> buffer) {
|
||||
CRYPTPROTECTMEMORY_SAME_PROCESS)) {
|
||||
return true;
|
||||
}
|
||||
if (::GetLastError() == ERROR_WORKING_SET_QUOTA) {
|
||||
base::TerminateBecauseOutOfMemory(0);
|
||||
}
|
||||
#endif // BUILDFLAG(IS_WIN)
|
||||
return false;
|
||||
}
|
||||
|
Reference in New Issue
Block a user