mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-01-12 10:29:39 +00:00
doc/examples/hw_decode: Remove logically dead code in decode_write()
Fixes CID1415951 Reviewed-by: Jun Zhao <mypopydev@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
49a0b3f6bc
commit
b3e9f3f5f5
@ -86,7 +86,7 @@ static int decode_write(AVCodecContext *avctx, AVPacket *packet)
|
||||
return ret;
|
||||
}
|
||||
|
||||
while (ret >= 0) {
|
||||
while (1) {
|
||||
if (!(frame = av_frame_alloc()) || !(sw_frame = av_frame_alloc())) {
|
||||
fprintf(stderr, "Can not alloc frame\n");
|
||||
ret = AVERROR(ENOMEM);
|
||||
@ -142,8 +142,6 @@ static int decode_write(AVCodecContext *avctx, AVPacket *packet)
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
|
Loading…
Reference in New Issue
Block a user