AudioStream: Work around uninitialized read in cubeb

This commit is contained in:
chaoticgd
2026-07-18 22:40:17 +02:00
committed by lightningterror
parent 3dbe303ee4
commit baca4179f0
+2 -2
View File
@@ -205,7 +205,7 @@ bool CubebAudioStream::Initialize(const char* driver_name, const char* device_na
}
cubeb_devid selected_device = nullptr;
cubeb_device_collection devices;
cubeb_device_collection devices = {};
bool devices_valid = false;
if (device_name && *device_name)
{
@@ -350,7 +350,7 @@ std::vector<AudioStream::DeviceInfo> AudioStream::GetCubebOutputDevices(const ch
ScopedGuard context_cleanup([context]() { cubeb_destroy(context); });
cubeb_device_collection devices;
cubeb_device_collection devices = {};
rv = cubeb_enumerate_devices(context, CUBEB_DEVICE_TYPE_OUTPUT, &devices);
if (rv != CUBEB_OK)
{