mirror of
https://github.com/FreeRDP/FreeRDP.git
synced 2024-11-23 09:54:26 +08:00
channels/rdpsnd: fix potential uninitialized value
This commit is contained in:
parent
e9d362b58e
commit
e45f149db4
@ -199,17 +199,15 @@ void rdpsnd_send_client_audio_formats(rdpsndPlugin* rdpsnd)
|
||||
UINT16 wNumberOfFormats;
|
||||
AUDIO_FORMAT* clientFormat;
|
||||
|
||||
dwVolumeLeft = ((50 * 0xFFFF) / 100); /* 50% */
|
||||
dwVolumeRight = ((50 * 0xFFFF) / 100); /* 50% */
|
||||
dwVolume = (dwVolumeLeft << 16) | dwVolumeRight;
|
||||
|
||||
if (rdpsnd->device)
|
||||
{
|
||||
if (rdpsnd->device->GetVolume)
|
||||
dwVolume = rdpsnd->device->GetVolume(rdpsnd->device);
|
||||
}
|
||||
else
|
||||
{
|
||||
dwVolumeLeft = ((50 * 0xFFFF) / 100); /* 50% */
|
||||
dwVolumeRight = ((50 * 0xFFFF) / 100); /* 50% */
|
||||
dwVolume = (dwVolumeLeft << 16) | dwVolumeRight;
|
||||
}
|
||||
|
||||
wNumberOfFormats = rdpsnd->NumberOfClientFormats;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user