summaryrefslogtreecommitdiff
path: root/apps/codecs/demac/libdemac/decoder.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/codecs/demac/libdemac/decoder.c')
-rw-r--r--apps/codecs/demac/libdemac/decoder.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/apps/codecs/demac/libdemac/decoder.c b/apps/codecs/demac/libdemac/decoder.c
index 31bcb28b72..30ab2bd359 100644
--- a/apps/codecs/demac/libdemac/decoder.c
+++ b/apps/codecs/demac/libdemac/decoder.c
@@ -82,7 +82,6 @@ int ICODE_ATTR_DEMAC decode_chunk(struct ape_ctx_t* ape_ctx,
82 int32_t* decoded0, int32_t* decoded1, 82 int32_t* decoded0, int32_t* decoded1,
83 int count) 83 int count)
84{ 84{
85 int res;
86 int32_t left, right; 85 int32_t left, right;
87#ifdef ROCKBOX 86#ifdef ROCKBOX
88 int scale = (APE_OUTPUT_DEPTH - ape_ctx->bps); 87 int scale = (APE_OUTPUT_DEPTH - ape_ctx->bps);
@@ -93,11 +92,11 @@ int ICODE_ATTR_DEMAC decode_chunk(struct ape_ctx_t* ape_ctx,
93 92
94 if ((ape_ctx->channels==1) || (ape_ctx->frameflags & APE_FRAMECODE_PSEUDO_STEREO)) { 93 if ((ape_ctx->channels==1) || (ape_ctx->frameflags & APE_FRAMECODE_PSEUDO_STEREO)) {
95 if (ape_ctx->frameflags & APE_FRAMECODE_STEREO_SILENCE) { 94 if (ape_ctx->frameflags & APE_FRAMECODE_STEREO_SILENCE) {
96 res = entropy_decode(ape_ctx, inbuffer, firstbyte, bytesconsumed, decoded0, decoded1, count); 95 entropy_decode(ape_ctx, inbuffer, firstbyte, bytesconsumed, decoded0, decoded1, count);
97 /* We are pure silence, so we're done. */ 96 /* We are pure silence, so we're done. */
98 return 0; 97 return 0;
99 } else { 98 } else {
100 res = entropy_decode(ape_ctx, inbuffer, firstbyte, bytesconsumed, decoded0, NULL, count); 99 entropy_decode(ape_ctx, inbuffer, firstbyte, bytesconsumed, decoded0, NULL, count);
101 } 100 }
102 101
103 switch (ape_ctx->compressiontype) 102 switch (ape_ctx->compressiontype)
@@ -143,7 +142,7 @@ int ICODE_ATTR_DEMAC decode_chunk(struct ape_ctx_t* ape_ctx,
143 return 0; 142 return 0;
144 } 143 }
145 144
146 res = entropy_decode(ape_ctx, inbuffer, firstbyte, bytesconsumed, decoded0, decoded1, count); 145 entropy_decode(ape_ctx, inbuffer, firstbyte, bytesconsumed, decoded0, decoded1, count);
147 146
148 /* Apply filters - compression type 1000 doesn't have any */ 147 /* Apply filters - compression type 1000 doesn't have any */
149 switch (ape_ctx->compressiontype) 148 switch (ape_ctx->compressiontype)
@@ -184,6 +183,5 @@ int ICODE_ATTR_DEMAC decode_chunk(struct ape_ctx_t* ape_ctx,
184 } 183 }
185 } 184 }
186 } 185 }
187 186 return 0;
188 return res;
189} 187}