File ImageMagick-CVE-2018-9135.patch of Package ImageMagick.8212

--- a/coders/webp.c
+++ b/coders/webp.c
@@ -181,6 +181,8 @@ static MagickBooleanType IsWEBPImageLossless(const unsigned char *stream,
   /*
     Read simple header.
   */
+  if (length <= VP8_CHUNK_INDEX)
+    return(MagickFalse);
   if (stream[VP8_CHUNK_INDEX] != EXTENDED_HEADER)
     return(stream[VP8_CHUNK_INDEX] == LOSSLESS_FLAG ? MagickTrue : MagickFalse);
   /*