[FFmpeg-soc] [soc]: r5119 - als/alsdec.c

Reimar Döffinger Reimar.Doeffinger at gmx.de
Sat Aug 15 13:38:53 CEST 2009


On Sat, Aug 15, 2009 at 01:27:24PM +0200, thilo.borgmann wrote:
> Author: thilo.borgmann
> Date: Sat Aug 15 13:27:23 2009
> New Revision: 5119
> 
> Log:
> Remove unnecessary braces.
> 
> Modified:
>    als/alsdec.c
> 
> Modified: als/alsdec.c
> ==============================================================================
> --- als/alsdec.c	Sat Aug 15 13:25:03 2009	(r5118)
> +++ als/alsdec.c	Sat Aug 15 13:27:23 2009	(r5119)
> @@ -486,11 +486,10 @@ static int read_block_data(ALSDecContext
>          if (const_block) {
>              unsigned int const_val_bits;
>  
> -            if (sconf->resolution == 2 || sconf->floating) {
> +            if (sconf->resolution == 2 || sconf->floating)
>                  const_val_bits = 24;
> -            } else {
> +            else
>                  const_val_bits = avctx->bits_per_raw_sample;
> -            }

Note that the {} of the if part do not add an extra line of code, so
e.g. Michael prefers to keep them.
Also this would IMO be simpler as
const_val_bits = sconf->resolution == 2 || sconf->floating ? 24 : avctx->bits_per_raw_sample;
(mostly because it is obvious that in both paths const_val_bits is set.


More information about the FFmpeg-soc mailing list