# HG changeset patch # User Jamie Bullock # Date 1301479507 0 # Node ID 571c53e87dbd198bed2ab77c3e073a00256ed91b # Parent 25fc4d0767f92ed8efcc6c73d35bcdea48bb6f44 - fixed typos in *result initialisation potentially fixing horrible bug diff -r 25fc4d0767f9 -r 571c53e87dbd src/Makefile.am --- a/src/Makefile.am Mon Aug 23 11:28:39 2010 +0000 +++ b/src/Makefile.am Wed Mar 30 10:05:07 2011 +0000 @@ -13,3 +13,5 @@ libxtract_la_CFLAGS = $(FFT_DEFINE) libxtract_la_SOURCES = $(SOURCES) libxtract_la_LDFLAGS = -export-dynamic + +EXTRA_DIST = xtract_globals_private.h xtract_macros_private.h xtract_window_private.h diff -r 25fc4d0767f9 -r 571c53e87dbd src/scalar.c --- a/src/scalar.c Mon Aug 23 11:28:39 2010 +0000 +++ b/src/scalar.c Wed Mar 30 10:05:07 2011 +0000 @@ -74,7 +74,7 @@ int n = N; - *result += 0.f; + *result = 0.f; while(n--) *result += powf(data[n] - *(float *)argv, 2); @@ -95,7 +95,7 @@ int n = N; - *result += 0.f; + *result = 0.f; while(n--) *result += fabsf(data[n] - *(float *)argv); @@ -111,7 +111,7 @@ float temp = 0.f; - *result += 0.f; + *result = 0.f; while(n--){ temp = (data[n] - ((float *)argv)[0]) / ((float *)argv)[1]; @@ -130,7 +130,7 @@ float temp = 0.f; - *result += 0.f; + *result = 0.f; while(n--){ temp = (data[n] - ((float *)argv)[0]) / ((float *)argv)[1]; @@ -183,7 +183,7 @@ amps = data; freqs = data + m; - *result += 0.f; + *result = 0.f; while(m--){ A += amps[m]; @@ -213,7 +213,7 @@ amps = data; freqs = data + m; - *result += 0.f; + *result = 0.f; while(m--){ A += amps[m]; @@ -236,7 +236,7 @@ amps = data; freqs = data + m; - *result += 0.f; + *result = 0.f; while(m--){ A += amps[m]; @@ -261,7 +261,7 @@ amps = data; freqs = data + m; - *result += 0.f; + *result = 0.f; while(m--){ A += amps[m]; @@ -763,7 +763,7 @@ int n = N; - *result += 0.f; + *result = 0.f; while(n--) *result += (*data++ ? 1 : 0);