shorten: pass on error value from allocate_buffers() instead of returning -1
This commit is contained in:
parent
9e5e2c2d01
commit
a8055992c0
@ -306,7 +306,7 @@ static int decode_subframe_lpc(ShortenContext *s, int channel,
|
|||||||
|
|
||||||
static int read_header(ShortenContext *s)
|
static int read_header(ShortenContext *s)
|
||||||
{
|
{
|
||||||
int i;
|
int i, ret;
|
||||||
int maxnlpc = 0;
|
int maxnlpc = 0;
|
||||||
/* shorten signature */
|
/* shorten signature */
|
||||||
if (get_bits_long(&s->gb, 32) != AV_RB32("ajkg")) {
|
if (get_bits_long(&s->gb, 32) != AV_RB32("ajkg")) {
|
||||||
@ -342,8 +342,8 @@ static int read_header(ShortenContext *s)
|
|||||||
}
|
}
|
||||||
s->nwrap = FFMAX(NWRAP, maxnlpc);
|
s->nwrap = FFMAX(NWRAP, maxnlpc);
|
||||||
|
|
||||||
if (allocate_buffers(s))
|
if ((ret = allocate_buffers(s)) < 0)
|
||||||
return -1;
|
return ret;
|
||||||
|
|
||||||
init_offset(s);
|
init_offset(s);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user