diff --git a/gst/matroska/matroska-read-common.c b/gst/matroska/matroska-read-common.c
index f2f1ee1..a5caa2f 100644
--- a/gst/matroska/matroska-read-common.c
+++ b/gst/matroska/matroska-read-common.c
@@ -2401,7 +2401,7 @@ gst_matroska_read_common_parse_metadata_id_tag (GstMatroskaReadCommon * common,
       for (j = 0; j < common->src->len; j++) {
         GstMatroskaTrackContext *stream = g_ptr_array_index (common->src, j);
 
-        if (stream->uid == tgt) {
+        if (stream->uid == tgt && stream->pending_tags != NULL) {
           gst_tag_list_insert (stream->pending_tags, taglist,
               GST_TAG_MERGE_REPLACE);
           found = TRUE;
