Fixed issue simonyiszk/csdr#15 by fixing allocating size in bytes instead of size in amount of taps

pull/17/head
Rico van Genugten 2016-10-06 11:28:34 +00:00
rodzic 7ba726af5b
commit 12d7db8b49
1 zmienionych plików z 1 dodań i 1 usunięć

2
csdr.c
Wyświetl plik

@ -940,7 +940,7 @@ int main(int argc, char *argv[])
padded_taps_length = taps_length+(NEON_ALIGNMENT/4)-1 - ((taps_length+(NEON_ALIGNMENT/4)-1)%(NEON_ALIGNMENT/4));
fprintf(stderr,"padded_taps_length = %d\n", padded_taps_length);
taps = (float*) (float*)malloc(padded_taps_length+NEON_ALIGNMENT);
taps = (float*) (float*)malloc((padded_taps_length+NEON_ALIGNMENT)*sizeof(float));
fprintf(stderr,"taps = %x\n", taps);
taps = (float*)((((unsigned)taps)+NEON_ALIGNMENT-1) & ~(NEON_ALIGNMENT-1));
fprintf(stderr,"taps = %x\n", taps);