Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 93eb01fd authored by Martin Storsjo's avatar Martin Storsjo Committed by Jean-Baptiste Queru
Browse files

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
parent 281a5040
Loading
Loading
Loading
Loading
+2 −2
Original line number Original line Diff line number Diff line
@@ -357,9 +357,9 @@ VO_U32 VO_API voAACEncSetParam(VO_HANDLE hCodec, VO_S32 uParamID, VO_PTR pData)
		if(config.sampleRate%8000 == 0)
		if(config.sampleRate%8000 == 0)
			tmp =480;
			tmp =480;
		/* check the bitrate */
		/* 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.nChannelsOut > 160000) ||
		   (config.bitRate > config.sampleRate*6*config.nChannelsOut))
		   (config.bitRate > config.sampleRate*6*config.nChannelsOut)))
		{
		{
			config.bitRate = 640*config.sampleRate/tmp*config.nChannelsOut;
			config.bitRate = 640*config.sampleRate/tmp*config.nChannelsOut;