From d78686f7d49754875c51bc9cba121b022befadbb Mon Sep 17 00:00:00 2001 From: Jan Schmidt Date: Thu, 4 Aug 2016 22:21:16 +1000 Subject: [PATCH] hls: Avoid coverity warning about access off the end of an array. Fixes CID 1364755 --- ext/hls/m3u8.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/hls/m3u8.c b/ext/hls/m3u8.c index 05f9188..bdb4acf 100644 --- a/ext/hls/m3u8.c +++ b/ext/hls/m3u8.c @@ -1039,7 +1039,7 @@ gst_m3u8_hls_media_type_get_nick (GstHLSMediaType mtype) "subtitle", "closed-captions" }; - if (mtype < 0 || mtype > GST_HLS_N_MEDIA_TYPES) + if (mtype < 0 || mtype >= GST_HLS_N_MEDIA_TYPES) return "invalid"; return nicks[mtype]; -- 2.7.4