Commit b173e035 authored by James Almer's avatar James Almer

avcodec/hapqa_extract: fix two error return values

ret is 0 by default.
Reviewed-by: 's avatarMartin Vignali <martin.vignali@gmail.com>
Signed-off-by: 's avatarJames Almer <jamrial@gmail.com>
parent 2b6699f0
......@@ -66,6 +66,7 @@ static int hapqa_extract(AVBSFContext *bsf, AVPacket *pkt)
if ((section_type & 0x0F) != 0x0D) {
av_log(bsf, AV_LOG_ERROR, "Invalid section type for HAPQA %#04x.\n", section_type & 0x0F);
ret = AVERROR_INVALIDDATA;
goto fail;
}
......@@ -90,6 +91,7 @@ static int hapqa_extract(AVBSFContext *bsf, AVPacket *pkt)
if (check_texture(ctx, section_type) == 0){ /* the second texture is not the one to keep */
av_log(bsf, AV_LOG_ERROR, "No valid texture found.\n");
ret = AVERROR_INVALIDDATA;
goto fail;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment