Do a range check on the resulting octal
This commit is contained in:
parent
bbe10559e6
commit
70adb1252d
@ -62,7 +62,7 @@ unescape(char *s)
|
||||
q += (s[m] - '0') * factor;
|
||||
factor *= 8;
|
||||
}
|
||||
s[i] = q;
|
||||
s[i] = (q > 255) 255 : q;
|
||||
}
|
||||
|
||||
for (m = i + 1; m <= len - off; m++)
|
||||
|
Loading…
Reference in New Issue
Block a user