1
0
Fork 0
mirror of https://github.com/librespot-org/librespot.git synced 2025-10-03 01:39:28 +02:00

disable logging on rodio stream drop (#1557)

This commit is contained in:
Thang Pham 2025-08-26 18:51:23 -04:00 committed by GitHub
parent d073cb1997
commit 1a19d94063
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -193,7 +193,7 @@ fn create_sink(
AudioFormat::S16 => cpal::SampleFormat::I16, AudioFormat::S16 => cpal::SampleFormat::I16,
}; };
let stream = match rodio::OutputStreamBuilder::default() let mut stream = match rodio::OutputStreamBuilder::default()
.with_device(cpal_device.clone()) .with_device(cpal_device.clone())
.with_config(&config.config()) .with_config(&config.config())
.with_sample_format(sample_format) .with_sample_format(sample_format)
@ -206,6 +206,9 @@ fn create_sink(
} }
}; };
// disable logging on stream drop
stream.log_on_drop(false);
let sink = rodio::Sink::connect_new(stream.mixer()); let sink = rodio::Sink::connect_new(stream.mixer());
Ok((sink, stream)) Ok((sink, stream))
} }