summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* matroskademux: Fix extraction of multichannel WavPack1.14Sebastian Dröge2021-03-152-46/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | The old code had a couple of issues that all lead to potential memory safety bugs. - Use a constant for the Wavpack4Header size instead of using sizeof. It's written out into the data and not from the struct and who knows what special alignment/padding requirements some C compilers have. - gst_buffer_set_size() does not realloc the buffer when setting a bigger size than allocated, it only allows growing up to the maximum allocated size. Instead use a GstAdapter to collect all the blocks and take out everything at once in the end. - Check that enough data is actually available in the input and otherwise handle it an error in all cases instead of silently ignoring it. Among other things this fixes out of bounds writes because the code assumed gst_buffer_set_size() can grow the buffer and simply wrote after the end of the buffer. Thanks to Natalie Silvanovich for reporting. Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/859 Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/905>
* matroskademux: Initialize track context out parameter to NULL before parsingSebastian Dröge2021-03-151-0/+2
| | | | | | | | | | | | | | | Various error return paths don't set it to NULL and callers are only checking if the pointer is NULL. As it's allocated on the stack this usually contains random stack memory, and more often than not the memory of a previously parsed track. This then causes all kinds of memory corruptions further down the line. Thanks to Natalie Silvanovich for reporting. Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/858 Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/905>
* flacenc: Pass audio info from set_format() to query_total_samples() explicitlySebastian Dröge2020-10-141-4/+3
| | | | | | | | | | | | | | This fixes writing of the seek table header. gst_audio_encoder_get_audio_info() will still return old/unset audio info until set_format() has actually returned, which then results in query_total_samples() to always return 0. Thanks to Jacob Kauffmann for debugging this and finding the main cause. Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/756 Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/661>
* Use gst_element_class_set_metadata when passing dynamic stringsJordan Petridis2020-10-142-2/+2
| | | | | | | | | | gst_element_class_set_metadata is meant to only be used with static or inlined strings, which isn't the case for the 2 elements here resulting in use-after-free later on. https://gstreamer.freedesktop.org/documentation/gstreamer/gstelement.html?gi-language=c#gst_element_class_set_static_metadata Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/622>
* Release 1.14.51.14.5Tim-Philipp Müller2019-05-297-21/+842
|
* Update docsTim-Philipp Müller2019-05-2972-76/+76
|
* qtgl: Handle OPENGL header guard changesEdward Hervey2019-05-161-0/+15
| | | | | | | | | | | In 2018 khronos changed the gl header guards. If we don't detect this properly we would end up with plenty of symbol redifinition (since we would be importing twice the "same" header). Instead detect if the "newer" header was already included and if so define the "old" define to avoid this situation Fixes #523
* autotools: Explicitly pass --tag=CC to libtoolNirbheek Chauhan2019-05-162-0/+2
| | | | | | | Fixes a build error with the latest macOS: libtool: compile: unable to infer tagged configuration libtool: error: specify a tag with '--tag'
* rtph264depay: Fix handling or marker on STAP-ANicolas Dufresne2019-05-061-1/+6
| | | | | | | Only forward the marker for the last NAL of the STAP-A. Otherwise each NAL endup being assumed to be a full frame which may break rendering. Fixes 557
* rtph265depay; Fix handling of marker on aggregated packetNicolas Dufresne2019-05-061-1/+5
| | | | | | When multiple nals are aggrgated, the marker bit should be associated only with the last NAL of the packet. Otherwise we may break rendering in with AU alignment.
* meson: matroska: Ensure header dependency not only librarySeungha Yang2019-05-061-1/+1
| | | | Library existence does not guarantee header.
* v4l2transform: fix cdata caps leaksGuillaume Desmottes2019-05-061-0/+2
| | | | | | The cdata structure was freed but not its caps. It was already done in gst_v4l2_video_dec_subclass_init() and gst_v4l2_video_enc_subclass_init().
* v4l2: mark caps from probe as MAY_BE_LEAKEDGuillaume Desmottes2019-05-061-0/+4
|
* rtpssrcdemux: Forward serialized events to all padsNicolas Dufresne2019-05-061-1/+1
| | | | | | | | | While forwarding serialized event, we use gst_pad_forward() function. In the forward callback (GstPadForwardFunction) we always return TRUE. Returning true there will stop the dispatching procedure. As a side effect, only one events is receiving the events. This breaks when sending EOS from the applicaiton, it also breaks the latency tracer.
* rtprawdepay: Don't get rid of the buffer pool on FLUSH_STOPSebastian Dröge2019-05-061-5/+6
| | | | | | | | We expect there to be a pool as long as the caps are known and FLUSH_STOP is not resetting the caps. Getting rid of the pool would cause assertions. Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/issues/584
* matroskamux: Fix typo in error messageSebastian Dröge2019-05-061-3/+3
|
* jack: Use jack_free(3) to release portsokuoku2019-05-062-5/+5
| | | | | | | | | Port objects acquired with jack_get_ports() need to be freed with jack_free(3), not stdlib free(). On Windows, Jack may be linked against different libc than GStreamer libraries so free()ing port objects directly might cause crash because of libc mismatch.
* v4l2: fix use after free when handling eventsGuillaume Desmottes2019-05-063-6/+9
| | | | | The sink_event parent function may consume the event so we shouldn't use it after having calling it.
* shout2: Fix leak on error in startNicolas Dufresne2019-05-061-0/+2
|
* flvmux: Fix scale of time values in warning messageAndreas Frisch2019-05-061-2/+2
|
* rtspsrc: Don't remove udpsrc/sink from rtspsrc if they were not added to itSebastian Dröge2019-05-061-2/+6
| | | | | | | This can happen in various error cases that could happen between the creation of the element in question and the adding to the rtspsrc. It causes an ugly critical warning right now but is otherwise harmless.
* v4l2sink: fix pool-less allocation query handlingPhilipp Zabel2019-05-061-2/+3
| | | | | | | | | | | This fixes a critical warning if the last-sample property is enabled: (gst-launch-1.0:391): GStreamer-CRITICAL **: 01:12:57.428: gst_object_unref: assertion 'object != NULL' failed If the allocation query does not contain any allocation pools, gst_query_parse_nth_allocation_pool will leave the local pool, min, and max variables undefined, so check the array length first. If pool is NULL, do not call gst_object_unref.
* flvmux: Use 8kHz sample rate for alaw/mulaw audioIlya Smelykh2019-05-061-3/+4
|
* flvdemux: set sample rate to 8KHz for G.711 audioIlya Smelykh2019-05-061-3/+3
|
* vpx: Fix build against libvpx 1.8Jan Alexander Steffens (heftig)2019-05-063-0/+10
| | | | The deprecated debug visualizer was removed.
* pulsesink: Deal with not being able to convert a format to capsArun Raghavan2019-05-061-2/+3
| | | | | | It is possible that PulseAudio adds formats that are not yet supported in pulsesink, and in those cases, we want to gracefully skip them rather than cause an assert on a NULL caps.
* flvdemux: Do not error out if the first added and chained pad is not linkedThibault Saunier2019-05-061-1/+2
| | | | | | | | | | | | | | | | | | | And let it the oportunity to get its other pad linked Example: ``` $ gst-launch-1.0 uridecodebin uri=file:///home/thiblahute/gst-validate.save/gst-integration-testsuites/testsuites/../medias/defaults/flv/819290236.flv caps=audio/x-raw expose-all-streams=FALSE ! fakesink Setting pipeline to PAUSED ... Pipeline is PREROLLING ... ERROR: from element /GstPipeline:pipeline0/GstURIDecodeBin:uridecodebin0/GstDecodeBin:decodebin0/GstFlvDemux:flvdemux0: Internal data stream error. Additional debug info: ../subprojects/gst-plugins-good/gst/flv/gstflvdemux.c(2760): gst_flv_demux_loop (): /GstPipeline:pipeline0/GstURIDecodeBin:uridecodebin0/GstDecodeBin:decodebin0/GstFlvDemux:flvdemux0: streaming stopped, reason not-linked (-1) ERROR: pipeline doesn't want to preroll. Setting pipeline to NULL ... Freeing pipeline ... ```
* webmmux: allow resolutions above 4096Christopher Snowhill2019-05-061-2/+2
| | | | | | | | | Modify the caps string to allow width and height greater than 4096. There is no need to restrict it since the matroska format allows the width and height values to be up to eight bytes long, and this also applies to the webm subset of the format. Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/issues/550
* gdkpixbufdec: always output a TIME segmentMathieu Duponchelle2019-05-061-0/+12
| | | | | | | | | | | | It makes no sense for a decoder to output a BYTES segment, and many elements one would plug downstream of a video decoder assume the segments they receive are in TIME format, for example this fixes: gst-validate-1.0 filesrc location=opacity01.svg ! gdkpixbufdec ! \ videobalance ! videoconvert ! fakesink In that case, videobalance was emitting an assertion when trying to call gst_object_sync_values()
* pulse: Fix format info to caps conversion for PCMArun Raghavan2019-05-061-1/+1
|
* pulsesrc: fix checking for invalid stream indexMarc-André Lureau2019-05-061-3/+3
| | | | | | | PA_INVALID_INDEX, the default value, is unfortunately !0. Setting the volume before the stream is created will put the ring buffer in error state. Unfortunately, that's what spice-gtk does.
* matroskademux: Don't leak allocated index memorySeungha Yang2019-05-061-0/+2
| | | | Don't forget to free returned memory from _search_pos()
* qtdemux: Offset correction for track language code parsingPhilippe Normand2019-05-061-2/+2
| | | | | | The duration field being a uint64, is stored in 8 bytes, not 4. So the offset of the following field, language code, needs to be updated accordingly so that the parsed language code is not garbage.
* osxcoreaudio: fix typoNicola Murino2019-05-061-1/+1
| | | | | | kAudioFormatFlagIsSignedInteger is a format flags Closes #394
* rtpjitterbuffer test: Stop jitterbuffer before pads to avoid raceOlivier Crête2019-05-061-0/+1
| | | | | | | The teardown of the pads checks the refcount, but there are timers inside the jitterbuffer that can push things, so if we're not lucky, things could be pushed while the pads are being shut down. Putting the jitterbuffer to NULL first avoids this.
* matroskademux: fix handling of MS ACM audioMatej Knopp2019-05-011-2/+2
| | | | | | | | | Pass riff codec-data as strf, not strd, which is where gst_riff_create_audio_caps() expects the WAVEFORMATEXTENSIBLE data. https://bugzilla.gnome.org/show_bug.cgi?id=757583 Fixes #234
* aspectcropration: Fix potential unref of NULL pointerThibault Saunier2019-05-011-1/+1
|
* aspectcropratio: Set caps from the streaming thread on property changesThibault Saunier2019-05-012-5/+31
| | | | | | | | Otherwise it might lead to deadlocks See https://gitlab.gnome.org/GNOME/pitivi/issues/2259 Closes #518
* matroska-ids: Fix uninitialized memory in contextsJohan Bjäreholt2019-05-011-0/+3
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=797327
* matroska: fix handling of FlagInterlacedTim-Philipp Müller2019-05-014-21/+59
| | | | | | | | This is an enum not a boolean, and a value of 2 signals that the video is progressive, but we would mistakenly set interlace-mode=mixed on the output caps. https://bugzilla.gnome.org/show_bug.cgi?id=787206
* avidemux: fix misleading debug lineWim Taymans2019-05-011-1/+1
|
* rtpmp4gdepay: detect broken senders who send AAC with ADTS framesTim-Philipp Müller2019-05-012-0/+24
| | | | | | | Strip ADTS headers if we detect any, apparently some Sony cameras send AAC with ADTS headers. We could also change the stream-format in the output caps, but that would be unexpected to pipeline builders and would not exactly be backwards compatible.
* flvmux: Don't leak codec_data bufferSeungha Yang2019-05-011-2/+2
| | | | | | Use gst_buffer_replace() to prevent buffer leak https://bugzilla.gnome.org/show_bug.cgi?id=797179
* rtph264depay: fix caps leakTim-Philipp Müller2019-03-121-0/+1
| | | | Exposed by rtp_h264depay_bytestream() unit test.
* meson: detect opengl api from -base .pc files correctlyTim-Philipp Müller2019-01-221-1/+5
| | | | | | | | | | | | | | There was a mismatch between the .pc files generated by autotools and by meson that would lead to meson not detecting that opengl api is available even though it is, if -base was built with autotools. The mismatch has now been rectified in -base, but we still check the old one for backwards compatibility. This is mostly for consistency, this problem didn't seem to affect anything in -good. See https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/871
* v4l2videodec: Move capture probe after input format is setNicolas Dufresne2018-11-071-15/+14
| | | | | | | | | | This is to support Amlogic CODEC driver which does not provide a full list of formats when the driver is initially opened. GStreamer does not strictly need this full list initially, but only later, in order to negotiate with downstream if multiple format can be selected. With this change, we will no longer probe twice the device, since the probed list can be directly used for negotation.
* rtpbin: Sink jitterbuffer/storage before passing as parameters to signalsSebastian Dröge2018-11-071-0/+14
| | | | | | | | Otherwise signal handlers from bindings will take ownership of them as they are still floating, and we won't own a reference inside rtpbin anymore. Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/issues/515
* flvmux: Force timestamps to always be increasingOlivier Crête2018-11-072-0/+16
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=796382
* qtdemux: Ignore corrupted CTTS boxSeungha Yang2018-11-071-0/+12
| | | | | | | | If ctts (CompositionOffsetBox) has larger sample_offset (offset between PTS and DTS) than (2 * duration) of the stream, assume the ctts box to be corrupted and ignore the box. https://bugzilla.gnome.org/show_bug.cgi?id=797262
* udpsrc: print information about bind_error socket errorMarc Leeman2018-11-071-1/+3
| | | | | | | | In some cases, a bind error occurs during operation. Printing the information about the problem is critical for finding the conflict https://bugzilla.gnome.org/show_bug.cgi?id=797340