Otherwise we'd be working with a NULL buffer and cause various critical
warnings along the way.
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/1104
GstMapInfo map;
guint8 *outdata;
+ if (!s->buf)
+ return GST_FLOW_OK;
+
target = s->size - s->current_size;
gst_buffer_map (s->buf, &map, GST_MAP_WRITE);
if (s->mngr.info.encoding == GST_PNM_ENCODING_ASCII) {
/* One last go at outputting any final value */
gst_pnmdec_parse_ascii (s, 0, 0);
- if (s->size <= s->current_size) {
+ if (s->size && s->size <= s->current_size) {
return gst_video_decoder_have_frame (decoder);
}
}