[libxml2] Add a missing argument check
- From: Daniel Veillard <veillard src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libxml2] Add a missing argument check
- Date: Mon, 14 Jul 2014 08:10:23 +0000 (UTC)
commit 7d2e8c950f1f017f5f3a45f999e5a3aad3e699da
Author: Gaurav Gupta <g gupta samsung com>
Date: Mon Jul 14 16:08:28 2014 +0800
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
relaxng.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/relaxng.c b/relaxng.c
index 1ba4fba..4273db3 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) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]