Skip to content

Commit 07ceb0f

Browse files
committed
Merge pull request #102069 from goatchurchprime/gtch/pamaxlength
Initialize pa_buffer_attr.maxlength to -1
2 parents 583b6ae + b5622e9 commit 07ceb0f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

drivers/pulseaudio/audio_driver_pulseaudio.cpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -725,7 +725,8 @@ Error AudioDriverPulseAudio::init_input_device() {
725725
int input_buffer_frames = closest_power_of_2(input_latency * mix_rate / 1000);
726726
int input_buffer_size = input_buffer_frames * spec.channels;
727727

728-
pa_buffer_attr attr;
728+
pa_buffer_attr attr = {};
729+
attr.maxlength = (uint32_t)-1;
729730
attr.fragsize = input_buffer_size * sizeof(int16_t);
730731

731732
pa_rec_str = pa_stream_new(pa_ctx, "Record", &spec, &pa_rec_map);

0 commit comments

Comments
 (0)