Changes in / [52d6145:2525f81]
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/io/utils_apple_audio.c
r52d6145 r2525f81 5 5 // ExtAudioFileRef, AudioStreamBasicDescription, AudioBufferList, ... 6 6 #include <AudioToolbox/AudioToolbox.h> 7 #include "aubio_priv.h" 7 8 8 9 int createAubioBufferList(AudioBufferList *bufferList, int channels, int segmentSize); … … 13 14 bufferList->mNumberBuffers = 1; 14 15 bufferList->mBuffers[0].mNumberChannels = channels; 15 bufferList->mBuffers[0].mData = (short *)malloc(segmentSize * sizeof(short));16 bufferList->mBuffers[0].mData = AUBIO_ARRAY(short, segmentSize); 16 17 bufferList->mBuffers[0].mDataByteSize = segmentSize * sizeof(short); 17 18 return 0; … … 23 24 for (i = 0; i < bufferList->mNumberBuffers; i++) { 24 25 if (bufferList->mBuffers[i].mData) { 25 free(bufferList->mBuffers[i].mData);26 AUBIO_FREE(bufferList->mBuffers[i].mData); 26 27 bufferList->mBuffers[i].mData = NULL; 27 28 } -
tests/src/io/test-source_seek.c
r52d6145 r2525f81 23 23 uint_t hop_size = 256; 24 24 uint_t n_frames = 0, read = 0; 25 uint_t old_n_frames; 25 26 if ( argc == 3 ) samplerate = atoi(argv[2]); 26 27 if ( argc == 4 ) hop_size = atoi(argv[3]); … … 46 47 aubio_source_seek (s, 0); 47 48 49 old_n_frames = n_frames; 50 48 51 n_frames = 0; 49 52 do { … … 60 63 del_fvec (vec); 61 64 65 assert ( n_frames == old_n_frames ); 62 66 return err; 63 67 }
Note: See TracChangeset
for help on using the changeset viewer.