https://github.com/ImageMagick/ImageMagick6/pull/63
diff --git a/coders/svg.c b/coders/svg.c index 55cba55..16accb2 100644 --- a/coders/svg.c +++ b/coders/svg.c
@@ -1669,18 +1669,14 @@ const char *p; - for (p=value; ; ) - { + p=value; + (void) GetNextToken(p,&p,MagickPathExtent,token); + if (*token == ',') (void) GetNextToken(p,&p,MagickPathExtent,token); - if (*token == ',') - (void) GetNextToken(p,&p,MagickPathExtent,token); - if (*token != '\0') - { - (void) FormatLocaleFile(svg_info->file,"class \"%s\"\n", - value); - break; - } - } + if (*token != '\0') + (void) FormatLocaleFile(svg_info->file,"class \"%s\"\n",value); + else + (void) FormatLocaleFile(svg_info->file,"class \"none\"\n"); break; } if (LocaleCompare(keyword,"clip-path") == 0)