Replace calls to assert() with RTC_DCHECK_*() in .c code
We have RTC_CHECK and RTC_DCHECK for C now, so we should use it. It's
one fewer difference between our C and C++ code.
NOPRESUBMIT=true
Review-Url: https://codereview.webrtc.org/2274083002
Cr-Commit-Position: refs/heads/master@{#13930}
diff --git a/webrtc/common_audio/signal_processing/min_max_operations_mips.c b/webrtc/common_audio/signal_processing/min_max_operations_mips.c
index 28de45b..c769e6a 100644
--- a/webrtc/common_audio/signal_processing/min_max_operations_mips.c
+++ b/webrtc/common_audio/signal_processing/min_max_operations_mips.c
@@ -16,8 +16,7 @@
*
*/
-#include <assert.h>
-
+#include "webrtc/base/checks.h"
#include "webrtc/common_audio/signal_processing/include/signal_processing_library.h"
// Maximum absolute value of word16 vector.
@@ -26,7 +25,7 @@
int32_t tmp32_0, tmp32_1, tmp32_2, tmp32_3;
size_t i, loop_size;
- assert(length > 0);
+ RTC_DCHECK_GT(length, 0);
#if defined(MIPS_DSP_R1)
const int32_t* tmpvec32 = (int32_t*)vector;
@@ -230,7 +229,7 @@
uint32_t absolute = 0, maximum = 0;
int tmp1 = 0, max_value = 0x7fffffff;
- assert(length > 0);
+ RTC_DCHECK_GT(length, 0);
__asm__ volatile (
".set push \n\t"
@@ -264,7 +263,7 @@
int tmp1;
int16_t value;
- assert(length > 0);
+ RTC_DCHECK_GT(length, 0);
__asm__ volatile (
".set push \n\t"
@@ -292,7 +291,7 @@
int32_t maximum = WEBRTC_SPL_WORD32_MIN;
int tmp1, value;
- assert(length > 0);
+ RTC_DCHECK_GT(length, 0);
__asm__ volatile (
".set push \n\t"
@@ -322,7 +321,7 @@
int tmp1;
int16_t value;
- assert(length > 0);
+ RTC_DCHECK_GT(length, 0);
__asm__ volatile (
".set push \n\t"
@@ -351,7 +350,7 @@
int32_t minimum = WEBRTC_SPL_WORD32_MAX;
int tmp1, value;
- assert(length > 0);
+ RTC_DCHECK_GT(length, 0);
__asm__ volatile (
".set push \n\t"