python: Update audiotestsrc to return correct tuple on FlowReturn Errors

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1259>
This commit is contained in:
Chris Wiggins 2021-10-27 17:20:39 +13:00
parent 20b87e39e9
commit 1e6d26ac2b

View file

@ -174,7 +174,7 @@ class AudioTestSrc(GstBase.BaseSrc):
array[:] = 0 array[:] = 0
except Exception as e: except Exception as e:
Gst.error("Mapping error: %s" % e) Gst.error("Mapping error: %s" % e)
return Gst.FlowReturn.ERROR return (Gst.FlowReturn.ERROR, None)
buf.offset = self.next_sample buf.offset = self.next_sample
buf.offset_end = next_sample buf.offset_end = next_sample