Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(153)

Unified Diff: webrtc/base/stringutils.cc

Issue 1429513004: Switch usage of _DEBUG macro to NDEBUG. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: REBASE Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/base/sigslot.h ('k') | webrtc/base/task.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/base/stringutils.cc
diff --git a/webrtc/base/stringutils.cc b/webrtc/base/stringutils.cc
index 868e475f2d6fac229372bcea2412c8438f0b5cff..9580253d1b2f56e6a7e4a166720301d34217ca6e 100644
--- a/webrtc/base/stringutils.cc
+++ b/webrtc/base/stringutils.cc
@@ -77,11 +77,11 @@ size_t asccpyn(wchar_t* buffer, size_t buflen,
} else if (srclen >= buflen) {
srclen = buflen - 1;
}
-#if _DEBUG
+#if !defined(NDEBUG)
// Double check that characters are not UTF-8
for (size_t pos = 0; pos < srclen; ++pos)
RTC_DCHECK_LT(static_cast<unsigned char>(source[pos]), 128);
-#endif // _DEBUG
+#endif
std::copy(source, source + srclen, buffer);
buffer[srclen] = 0;
return srclen;
« no previous file with comments | « webrtc/base/sigslot.h ('k') | webrtc/base/task.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698