diff --git a/src/nanosvg.h b/src/nanosvg.h index 098e5b2..e204bb7 100644 --- a/src/nanosvg.h +++ b/src/nanosvg.h @@ -177,7 +177,7 @@ static void nsvg__parseElement(char* s, if (*s) { *s++ = '\0'; } // Get attribs - while (!end && *s && nattr < NSVG_XML_MAX_ATTRIBS-1) { + while (!end && *s && nattr < NSVG_XML_MAX_ATTRIBS-3) { // Skip white space before the attrib name while (*s && nsvg__isspace(*s)) s++; if (!*s) break;