OSS: correct test for unsupported formats

Previously GetAvailableFormats returned paSampleFormatNotSupported if
AFMT_S16_NE was not supported, regardless of the supported state of any
other formats.  Instead, return paSampleFormatNotSupported if no
supported formats are found.
This commit is contained in:
Ed Maste 2021-01-19 15:00:09 -05:00 committed by Phil Burk
commit fc2a24d394

View file

@ -961,7 +961,7 @@ static PaError GetAvailableFormats( PaOssStreamComponent *component, PaSampleFor
frmts |= paInt8;
if( mask & AFMT_S16_NE )
frmts |= paInt16;
else
if( frmts == 0 )
result = paSampleFormatNotSupported;
*availableFormats = frmts;