summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorNick Wellnhofer <wellnhofer@aevum.de>2017-05-29 21:02:21 +0200
committerNick Wellnhofer <wellnhofer@aevum.de>2017-05-31 16:04:26 +0200
commita58331a6ee4d4c161cebfa4e0d9a090945c6bf23 (patch)
tree013cbe203d702ab746213eab1fddbd089f33527c /test
parenta851868a75c108e3b8fc507f5d6555b09abb51c9 (diff)
downloadlibxml2-a58331a6ee4d4c161cebfa4e0d9a090945c6bf23.tar.gz
Check for overflow in xmlXPathIsPositionalPredicate
Avoid undefined behavior when casting from double to int. Found with afl-fuzz and UBSan.
Diffstat (limited to 'test')
-rw-r--r--test/XPath/tests/chaptersbase3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/XPath/tests/chaptersbase b/test/XPath/tests/chaptersbase
index 17638f73..f8fbe2a8 100644
--- a/test/XPath/tests/chaptersbase
+++ b/test/XPath/tests/chaptersbase
@@ -8,3 +8,6 @@
/descendant::title
/descendant::p/ancestor::chapter
//p[1]
+//p[0 div 0]
+//p[100000000000000000000]
+//p[-100000000000000000000]