Skip to content

Commit

Permalink
Test for fuzz overflow in #1577
Browse files Browse the repository at this point in the history
Doesn't repro for me - fixed by another commit?
  • Loading branch information
jhy committed Jul 11, 2021
1 parent 9031164 commit 2b8253d
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/test/java/org/jsoup/integration/FuzzFixesTest.java
Expand Up @@ -100,4 +100,16 @@ public void scope1579() {
Document xmlDoc = Parser.xmlParser().parseInput(html, "");
assertNotNull(xmlDoc);
}

@Test
public void overflow1577() throws IOException {
// https://github.com/jhy/jsoup/issues/1577
// no repro - fixed elsewhere?
File in = ParseTest.getFile("/fuzztests/1577.html.gz");
Document doc = Jsoup.parse(in, "UTF-8");
assertNotNull(doc);

Document docXml = Jsoup.parse(new FileInputStream(in), "UTF-8", "https://example.com", Parser.xmlParser());
assertNotNull(docXml);
}
}
Binary file added src/test/resources/fuzztests/1577.html.gz
Binary file not shown.

0 comments on commit 2b8253d

Please sign in to comment.