mirror of
https://github.com/rkd77/elinks.git
synced 2024-12-04 14:46:47 -05:00
Fix another off-by-one error similar to the SGML comment parsing
This commit is contained in:
parent
ab7ba39d42
commit
e8ff8bd5f0
@ -210,7 +210,7 @@ skip_cdata_section(struct dom_scanner *scanner, unsigned char **string)
|
||||
unsigned char *pos = *string;
|
||||
int length = 0;
|
||||
|
||||
for (; pos < scanner->end - 3; pos++)
|
||||
for (; pos < scanner->end - 2; pos++)
|
||||
if (pos[0] == ']' && pos[1] == ']' && pos[2] == '>') {
|
||||
length = pos - *string;
|
||||
pos += 3;
|
||||
|
Loading…
Reference in New Issue
Block a user