avvidenc: Fix error propagation
authorEdward Hervey <edward@centricular.com>
Fri, 29 Nov 2019 08:25:24 +0000 (09:25 +0100)
committerEdward Hervey <bilboed@bilboed.com>
Fri, 29 Nov 2019 10:33:41 +0000 (11:33 +0100)
Instead of returning the default return value (GST_FLOW_OK), actually
return an error one (res vs ret).

ext/libav/gstavvidenc.c

index ca38d27..f9c4923 100644 (file)
@@ -654,7 +654,7 @@ gst_ffmpegvidenc_receive_packet (GstFFMpegVidEnc * ffmpegenc,
     ret = GST_FLOW_EOS;
     goto done;
   } else if (res < 0) {
-    res = GST_FLOW_ERROR;
+    ret = GST_FLOW_ERROR;
     goto done;
   }