src: replace ASSERT with CHECK

Builds always have asserts enabled so there is no point distinguishing
between debug-only checks and run-time checks.  Replace calls to ASSERT
and friends with their CHECK counterparts.

Fixes: https://github.com/nodejs/node/issues/14461
PR-URL: https://github.com/nodejs/node/pull/14474
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: XadillaX <admin@xcoder.in>
This commit is contained in:
Ben Noordhuis authored and Anna Henningsen committed 2017-07-27 23:48:54 +02:00
1 parent 4ff562f41e
commit eb7faf6734
11 files changed
+36 -58

No files matched your search

+1 -1
View File
@@ -321,7 +321,7 @@ size_t StringBytes::WriteUCS2(char* buf,
uint16_t* aligned_dst =
reinterpret_cast<uint16_t*>(buf + sizeof(*dst) - alignment);
ASSERT_EQ(reinterpret_cast<uintptr_t>(aligned_dst) % sizeof(*dst), 0);
CHECK_EQ(reinterpret_cast<uintptr_t>(aligned_dst) % sizeof(*dst), 0);
// Write all but the last char
nchars = str->Write(aligned_dst, 0, max_chars - 1, flags);