check_completed_gop crash
Describe your issue
The following pipeline causes gstreamer crash on Linux/Ubuntu 22.04, gstreamer 1.20.3: gst_crash.c
Expected Behavior
No crash
Observed Behavior
ERROR:../gst/multifile/gstsplitmuxsink.c:2691:check_completed_gop: assertion failed: (gop != NULL)
Bail out! ERROR:../gst/multifile/gstsplitmuxsink.c:2691:check_completed_gop: assertion failed: (gop != NULL)
Aborted (core dumped)
Setup
- Operating System: Linux/Ubuntu 22.04
- Device: Computer
- GStreamer Version: 1.20.3
-
Command line: see the
Steps to reproduce the bug
section below
Steps to reproduce the bug
Generate test jpeg image:
gst-launch-1.0 videotestsrc num-buffers=1 ! video/x-raw,width=1920,height=1080 ! jpegenc ! filesink location=gst-image.jpeg
Compile and run the example app (the crash does not happen on each run):
$ gcc -O0 -ggdb gst_crash.c $(pkg-config --libs --cflags gstreamer-1.0 gstreamer-base-1.0 gstreamer-video-1.0 gstreamer-pbutils-1.0)
$ ./a.out
Typefind found.
Obtained request pad src_0 for HLS branch.
Obtained request pad src_1 for thumbnails branch.
Error received from element jpegdec: No valid frames decoded before end of stream
Debugging information: ../gst-libs/gst/video/gstvideodecoder.c(1416): gst_video_decoder_sink_event_default (): /GstPipeline:test-pipeline/GstJpegDec:jpegdec:
no valid frames found
**
ERROR:../gst/multifile/gstsplitmuxsink.c:2691:check_completed_gop: assertion failed: (gop != NULL)
Bail out! ERROR:../gst/multifile/gstsplitmuxsink.c:2691:check_completed_gop: assertion failed: (gop != NULL)
Aborted (core dumped)
$
How reproducible is the bug?
Almost on every run
Solutions you have tried
I noticed that when reordering videoconvert
with videoscale
when linking the pipeline the crash disappear, i.e. when changing line 102 from:
gst_element_link_many (c.thumbnailsqueue, c.videoconvert, c.videoscale, c.pngenc, c.appsink, NULL) != TRUE) {
to:
gst_element_link_many (c.thumbnailsqueue, c.videoscale, c.videoconvert, c.pngenc, c.appsink, NULL) != TRUE) {