Commit e9d46063 authored by Sigurdur Asgeirsson's avatar Sigurdur Asgeirsson Committed by Commit Bot

Reland "Make SECURITY_DCHECK play with Albatross."

This is a reland of 06d64c00
Original change's description:
> Make SECURITY_DCHECK play with Albatross.
> 
> In Albatross builds, DCHECKs can be compiled in, but non-fatal. See
> https://docs.google.com/a/chromium.org/document/d/1QY4IbbJ8X6G-6-cMheEkP_mT7ZNPCuUJIW2sr_mEiH4
> 
> Bug: 596231
> Change-Id: I84198f1d3f4122ac7a5bd8a90ed5ea96286b9022
> Reviewed-on: https://chromium-review.googlesource.com/685498
> Reviewed-by: Wez <wez@chromium.org>
> Reviewed-by: Jochen Eisinger <jochen@chromium.org>
> Commit-Queue: Sigurður Ásgeirsson <siggi@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#504638}

Bug: 596231
Change-Id: I2c1223ba264dbdb06e814b92b84adfe9c3c619b7
Reviewed-on: https://chromium-review.googlesource.com/687874Reviewed-by: default avatarGabriel Charette <gab@chromium.org>
Reviewed-by: default avatarJochen Eisinger <jochen@chromium.org>
Commit-Queue: Sigurður Ásgeirsson <siggi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#505025}
parent bb75a7d4
......@@ -823,8 +823,9 @@ const LogSeverity LOG_DCHECK = LOG_FATAL;
#else // DCHECK_IS_ON()
// This is a dummy value, since the DCHECK implementation is a no-op.
const LogSeverity LOG_DCHECK = LOG_INFO;
// There may be users of LOG_DCHECK that are enabled independently
// of DCHECK_IS_ON(), so default to FATAL logging for those.
const LogSeverity LOG_DCHECK = LOG_FATAL;
#endif // DCHECK_IS_ON()
......
......@@ -61,7 +61,7 @@ WTF_EXPORT PRINTF_FORMAT(1, 2) // NOLINT
// https://bugs.chromium.org/p/chromium/issues/entry?template=Security%20Bug
#if ENABLE_SECURITY_ASSERT
#define SECURITY_DCHECK(condition) \
LOG_IF(FATAL, !(condition)) << "Security DCHECK failed: " #condition ". "
LOG_IF(DCHECK, !(condition)) << "Security DCHECK failed: " #condition ". "
// A SECURITY_CHECK failure is actually not vulnerable.
#define SECURITY_CHECK(condition) \
LOG_IF(FATAL, !(condition)) << "Security CHECK failed: " #condition ". "
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment