diff --git a/src/fm95.c b/src/fm95.c index 3a7f162..7ca8326 100644 --- a/src/fm95.c +++ b/src/fm95.c @@ -424,7 +424,7 @@ int setup_audio(FM95_Runtime* runtime, const FM95_DeviceNames dv_names, const FM if(config.options.mpx_on) free_PulseDevice(&runtime->mpx_device); return 1; } - runtime->rds_in = calloc(sizeof(float) * BUFFER_SIZE * config.rds_streams); + runtime->rds_in = malloc(sizeof(float) * BUFFER_SIZE * config.rds_streams); } printf("Connecting to output device... (%s)\n", dv_names.output); diff --git a/src/vban95.c b/src/vban95.c index b8de5bc..db80b63 100644 --- a/src/vban95.c +++ b/src/vban95.c @@ -35,13 +35,13 @@ typedef struct { } AudioBuffer; AudioBuffer* create_audio_buffer(int capacity) { - AudioBuffer* buffer = (AudioBuffer*)calloc(sizeof(AudioBuffer)); + AudioBuffer* buffer = (AudioBuffer*)malloc(sizeof(AudioBuffer)); if (!buffer) { perror("Failed to allocate audio buffer"); return NULL; } - buffer->packets = (AudioPacket*)calloc(capacity * sizeof(AudioPacket)); + buffer->packets = (AudioPacket*)malloc(capacity * sizeof(AudioPacket)); if (!buffer->packets) { perror("Failed to allocate packet buffer"); free(buffer);