Re: [xml] xmllint/Relax NG segfaulting
- From: Daniel Veillard <veillard redhat com>
- To: "William M. Brack" <wbrack mmm com hk>
- Cc: Martijn Faassen <faassen vet uu nl>, xml gnome org
- Subject: Re: [xml] xmllint/Relax NG segfaulting
- Date: Mon, 25 Aug 2003 06:51:52 -0400
On Mon, Aug 25, 2003 at 06:28:24PM +0800, William M. Brack wrote:
Give me a crash, and I'll give you a patch :-)
diff -u -r1.78 relaxng.c
--- relaxng.c 1 Aug 2003 15:55:39 -0000 1.78
+++ relaxng.c 25 Aug 2003 10:26:06 -0000
@@ -1075,6 +1075,7 @@
ctxt->error(ctxt->userData, "Out of memory\n");
return (ret);
}
+ ret->maxAttrs = nbAttrs;
ret->attrs = tmp;
}
ret->nbAttrs = nbAttrs;
@@ -1152,6 +1153,7 @@
ret->nbAttrs = 0;
return (ret);
}
+ ret->attrs = tmp;
ret->maxAttrs = state->maxAttrs;
}
memcpy(ret->attrs, state->attrs, state->nbAttrs *
sizeof(xmlAttrPtr));
Cool, we end up with exactly the same patch, which I was about to commit,
pending some checking from Igor's work on the headers :-)
I was probably a bit tired when I wrote that validation state caching
code <grin/>. This fixes 120040 too.
Daniel
--
Daniel Veillard | Red Hat Network https://rhn.redhat.com/
veillard redhat com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]