diff options
author | Nicolas Dufresne <nicolas.dufresne@collabora.com> | 2017-03-27 15:10:45 -0400 |
---|---|---|
committer | Nicolas Dufresne <nicolas.dufresne@collabora.com> | 2017-03-27 15:10:45 -0400 |
commit | 62d167b551bab7bc1793b40627925945cdeda558 (patch) | |
tree | eb8a166d134952a3e9600c4a8dc3821bd1ee3af4 /gst | |
parent | 18917de9562d0d33cf80ca68c071eee3572d4483 (diff) | |
download | gstreamer-plugins-bad-62d167b551bab7bc1793b40627925945cdeda558.tar.gz |
audiomixmatrix: Don't crash if matrix is unset
Fix a crash ff one set in_channels/out_channels to non-zero, and then
get the matrix property.
Diffstat (limited to 'gst')
-rw-r--r-- | gst/audiomixmatrix/gstaudiomixmatrix.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/gst/audiomixmatrix/gstaudiomixmatrix.c b/gst/audiomixmatrix/gstaudiomixmatrix.c index ec336337e..6dd59ffd9 100644 --- a/gst/audiomixmatrix/gstaudiomixmatrix.c +++ b/gst/audiomixmatrix/gstaudiomixmatrix.c @@ -356,6 +356,9 @@ gst_audio_mix_matrix_get_property (GObject * object, guint prop_id, case PROP_MATRIX:{ gint in, out; + if (self->matrix == NULL) + break; + for (out = 0; out < self->out_channels; out++) { GValue row = G_VALUE_INIT; g_value_init (&row, GST_TYPE_ARRAY); |