static int decode_block(ALSDecContext *ctx, ALSBlockData *bd)

{

    unsigned int smp;



    // read block type flag and read the samples accordingly

    if (*bd->const_block)

        decode_const_block_data(ctx, bd);

    else if (decode_var_block_data(ctx, bd))

        return -1;



    // TODO: read RLSLMS extension data



    if (*bd->shift_lsbs)

        for (smp = 0; smp < bd->block_length; smp++)

            bd->raw_samples[smp] <<= *bd->shift_lsbs;



    return 0;

}

static int decode_block(ALSDecContext *ctx, ALSBlockData *bd)

{

    unsigned int smp;



    

    if (*bd->const_block)

        decode_const_block_data(ctx, bd);

    else if (decode_var_block_data(ctx, bd))

        return -1;



    



    if (*bd->shift_lsbs)

        for (smp = 0; smp < bd->block_length; smp++)

            bd->raw_samples[smp] <<= *bd->shift_lsbs;



    return 0;

}

        return -1;         return -1;         return -1;         return -1;         return -1;         return -1;         return -1;     return 0;     else if (decode_var_block_data(ctx, bd))         return -1;         return -1;         return -1;         return -1;         return -1;         return -1;
static int FUNC_0(ALSDecContext *VAR_0, ALSBlockData *VAR_1)

{

    unsigned int VAR_2;



    

    if (*VAR_1->const_block)

        decode_const_block_data(VAR_0, VAR_1);

    else if (decode_var_block_data(VAR_0, VAR_1))

        return -1;



    



    if (*VAR_1->shift_lsbs)

        for (VAR_2 = 0; VAR_2 < VAR_1->block_length; VAR_2++)

            VAR_1->raw_samples[VAR_2] <<= *VAR_1->shift_lsbs;



    return 0;

}

static int FUNC_0(ALSDecContext *VAR_0, ALSBlockData *VAR_1)
{ unsigned int VAR_2; if (*VAR_1->const_block)
decode_const_block_data(VAR_0, VAR_1); else if (decode_var_block_data(VAR_0, VAR_1))
return -1; if (*VAR_1->shift_lsbs)
for (VAR_2 = 0; VAR_2 < VAR_1->block_length; VAR_2++) VAR_1->raw_samples[VAR_2] <<= *VAR_1->shift_lsbs; return 0; }