Changed spandsp from using TRUE and FALSE to using C99 true and false. It seems

like the quirks we used to get using those with C++ have gone away.
This commit is contained in:
Steve Underwood
2013-08-08 21:40:28 +08:00
parent bf9809c10c
commit 365fc08719
212 changed files with 3152 additions and 2664 deletions

View File

@@ -41,6 +41,11 @@
#if defined(HAVE_MATH_H)
#include <math.h>
#endif
#if defined(HAVE_STDBOOL_H)
#include <stdbool.h>
#else
#include "spandsp/stdbool.h"
#endif
#include "floating_fudge.h"
#include <assert.h>
@@ -48,6 +53,8 @@
#include "spandsp/alloc.h"
#include "spandsp/power_meter.h"
#include "spandsp/private/power_meter.h"
SPAN_DECLARE(power_meter_t *) power_meter_init(power_meter_t *s, int shift)
{
if (s == NULL)
@@ -148,14 +155,14 @@ SPAN_DECLARE(int32_t) power_surge_detector(power_surge_detector_state_t *s, int1
{
if (pow_short <= s->surge*(pow_medium >> 10))
return 0;
s->signal_present = TRUE;
s->signal_present = true;
s->medium_term.reading = s->short_term.reading;
}
else
{
if (pow_short < s->sag*(pow_medium >> 10))
{
s->signal_present = FALSE;
s->signal_present = false;
s->medium_term.reading = s->short_term.reading;
return 0;
}