Skip to content

Commit

Permalink
fix: crash when too big note duration
Browse files Browse the repository at this point in the history
Issue #75.
  • Loading branch information
moinejf committed Jul 25, 2020
1 parent 83c0bb3 commit 191fa55
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion abcparse.c
Original file line number Diff line number Diff line change
Expand Up @@ -1804,7 +1804,7 @@ static char *parse_len(char *p,
len = dur_u;
if (isdigit((unsigned char) *p)) {
len *= strtol(p, &q, 10);
if (len <= 0) {
if (len <= 0 || len > 1000) {
syntax("Bad length", p);
len = dur_u;
}
Expand Down

0 comments on commit 191fa55

Please sign in to comment.