diff options
author | Sebastian Dröge <sebastian@centricular.com> | 2015-08-18 15:58:57 +0300 |
---|---|---|
committer | Sebastian Dröge <sebastian@centricular.com> | 2015-08-18 15:58:57 +0300 |
commit | 2de91c32e416b9547561d331e167189cd87bb3bd (patch) | |
tree | 65fc43cad148268a2bd6a9bf539486933430de32 /gst-libs | |
parent | cca823b490e007a278335374163bb73604910c4f (diff) |
audioencoder: If there are no tags, don't try to do event handling on a NULL event
Fixes some crashes.
Diffstat (limited to 'gst-libs')
-rw-r--r-- | gst-libs/gst/audio/gstaudioencoder.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/gst-libs/gst/audio/gstaudioencoder.c b/gst-libs/gst/audio/gstaudioencoder.c index 2ff8430a8..17f843aeb 100644 --- a/gst-libs/gst/audio/gstaudioencoder.c +++ b/gst-libs/gst/audio/gstaudioencoder.c @@ -1641,6 +1641,12 @@ gst_audio_encoder_sink_event_default (GstAudioEncoder * enc, GstEvent * event) gst_event_unref (event); event = gst_audio_encoder_create_merged_tags_event (enc); GST_AUDIO_ENCODER_STREAM_UNLOCK (enc); + + /* No tags, go out of here instead of fall through */ + if (!event) { + res = TRUE; + break; + } } /* fall through */ } |