]> granicus.if.org Git - libvpx/commitdiff
webmdec: Handle codec id being NULL.
authorVignesh Venkatasubramanian <vigneshv@google.com>
Thu, 10 Sep 2015 17:44:59 +0000 (10:44 -0700)
committerVignesh Venkatasubramanian <vigneshv@google.com>
Thu, 10 Sep 2015 17:44:59 +0000 (10:44 -0700)
WebM files could have CodecId missing in the track headers. Treat those files as
unknown input file type in vpxdec.

Fixes issue #1064.

Change-Id: I6c3bb7b4bd3a4f5c244312482a5996f8b68db3f3

webmdec.cc

index 1020d046ba872bf416d5f4009e01c68de9b8c103..f541cfecc1692ebb6894d3ffa5efc42970249c2a 100644 (file)
@@ -94,7 +94,7 @@ int file_is_webm(struct WebmInputContext *webm_ctx,
     }
   }
 
-  if (video_track == NULL) {
+  if (video_track == NULL || video_track->GetCodecId() == NULL) {
     rewind_and_reset(webm_ctx, vpx_ctx);
     return 0;
   }