summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGaurav Gupta <g.gupta@samsung.com>2014-07-14 16:08:28 +0800
committerDaniel Veillard <veillard@redhat.com>2014-07-14 16:08:28 +0800
commit7d2e8c950f1f017f5f3a45f999e5a3aad3e699da (patch)
treec28e1bfe9c844149dba494d94f9e28f4f92cae1c
parent6d753994b9cdfccec5d0075d5685cae9ad06bec1 (diff)
downloadlibxml2-7d2e8c950f1f017f5f3a45f999e5a3aad3e699da.tar.gz
Add a missing argument check
For https://bugzilla.gnome.org/show_bug.cgi?id=733042 the states argument of xmlRelaxNGAddStates() ought to be checked too
-rw-r--r--relaxng.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/relaxng.c b/relaxng.c
index 1ba4fbab..4273db33 100644
--- a/relaxng.c
+++ b/relaxng.c
@@ -1095,7 +1095,7 @@ xmlRelaxNGAddStates(xmlRelaxNGValidCtxtPtr ctxt,
{
int i;
- if (state == NULL) {
+ if (state == NULL || states == NULL) {
return (-1);
}
if (states->nbState >= states->maxState) {