stagefright aacenc: Add parentheses in expression with mixed && and ||

This doesn't maintain the exact behaviour, but seems closer to
what the original author probably intended.

This avoids a warning.

Change-Id: I191292faa0a25f715f2b7d46ec770827e2ac0b7b
This commit is contained in:
Martin Storsjo
2012-01-12 14:45:41 +02:00
parent 67cf093d86
commit f4e7ff9e5a

View File

@@ -357,9 +357,9 @@ VO_U32 VO_API voAACEncSetParam(VO_HANDLE hCodec, VO_S32 uParamID, VO_PTR pData)
if(config.sampleRate%8000 == 0)
tmp =480;
/* check the bitrate */
if(config.bitRate!=0 && (config.bitRate/config.nChannelsOut < 4000) ||
if(config.bitRate!=0 && ((config.bitRate/config.nChannelsOut < 4000) ||
(config.bitRate/config.nChannelsOut > 160000) ||
(config.bitRate > config.sampleRate*6*config.nChannelsOut))
(config.bitRate > config.sampleRate*6*config.nChannelsOut)))
{
config.bitRate = 640*config.sampleRate/tmp*config.nChannelsOut;