Signed-off-by: sunzhenliang <hisunzhenli...@outlook.com>
---
 doc/examples/transcoding.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/doc/examples/transcoding.c b/doc/examples/transcoding.c
index badfba62cb..24e64e572e 100644
--- a/doc/examples/transcoding.c
+++ b/doc/examples/transcoding.c
@@ -524,8 +524,10 @@ int main(int argc, char **argv)
         goto end;
     if ((ret = init_filters()) < 0)
         goto end;
-    if (!(packet = av_packet_alloc()))
+    if (!(packet = av_packet_alloc())) {
+        ret = AVERROR(ENOMEM);
         goto end;
+    }
 
     /* read all packets */
     while (1) {
-- 
2.25.1

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Reply via email to