Skip to content

Commit

Permalink
Fix OOB read in nsvg__parseColorRGB() #262
Browse files Browse the repository at this point in the history
  • Loading branch information
oehhar committed Dec 19, 2024
1 parent d6593b0 commit 5df8ec9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion generic/nanosvg.h
Original file line number Diff line number Diff line change
Expand Up @@ -1341,7 +1341,7 @@ static unsigned int nsvg__parseColorRGB(const char* str)
while (*str && nsvg__isdigit(*str)) str++; /* skip fractional part */
}
if (*str == '%') str++; else break;
while (nsvg__isspace(*str)) str++;
while (*str && nsvg__isspace(*str)) str++;
if (*str == delimiter[i]) str++;
else break;
}
Expand Down

0 comments on commit 5df8ec9

Please sign in to comment.