]> granicus.if.org Git - imagemagick/commitdiff
(no commit message)
authorcristy <urban-warrior@git.imagemagick.org>
Sun, 19 May 2013 11:51:07 +0000 (11:51 +0000)
committercristy <urban-warrior@git.imagemagick.org>
Sun, 19 May 2013 11:51:07 +0000 (11:51 +0000)
coders/pnm.c

index 184f12cdf08d44c2de787e48e6316f52db7291b9..8c0d6b009933b05152daf82ea72f735164d753ac 100644 (file)
@@ -339,6 +339,16 @@ static Image *ReadPNMImage(const ImageInfo *image_info,ExceptionInfo *exception)
         {
           while (isspace((int) ((unsigned char) c)) != 0)
             c=ReadBlobByte(image);
+          if (c == '#')
+            {
+              /*
+                Comment.
+              */
+              while ((c != EOF) && (c != '\n'))
+                c=ReadBlobByte(image);
+              while (isspace((int) ((unsigned char) c)) != 0)
+                c=ReadBlobByte(image);
+            }
           p=keyword;
           do
           {