[vlc-commits] HLS: fix a signed comparison warning

Jean-Baptiste Kempf git at videolan.org
Wed May 23 19:33:39 CEST 2012


vlc/vlc-2.0 | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Mon May 21 16:51:34 2012 +0200| [b89e0273572cec446914321c781c402c9c35dd1d] | committer: Jean-Baptiste Kempf

HLS: fix a signed comparison warning
(cherry picked from commit a5b0a06c3a8a6c6276e172174405b40e6678b2a1)

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.0.git/?a=commit;h=b89e0273572cec446914321c781c402c9c35dd1d
---

 modules/stream_filter/httplive.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/stream_filter/httplive.c b/modules/stream_filter/httplive.c
index d54f42f..ea0a854 100644
--- a/modules/stream_filter/httplive.c
+++ b/modules/stream_filter/httplive.c
@@ -211,7 +211,7 @@ static bool isHTTPLiveStreaming(stream_t *s)
         for (size_t i = 0; i < ARRAY_SIZE(ext); i++)
         {
             size_t len = strlen(ext[i]);
-            if (size < len)
+            if (size < 0 || (size_t)size < len)
                 continue;
             if (!memcmp(peek, ext[i], len))
                 return true;



More information about the vlc-commits mailing list