Update of /cvsroot/perl-xml/XML-LibXML-XPathContext
In directory sc8-pr-cvs1:/tmp/cvs-serv959
Modified Files:
XPathContext.xs Changes
Log Message:
- minor bug fix for new without context node
Index: XPathContext.xs
===================================================================
RCS file: /cvsroot/perl-xml/XML-LibXML-XPathContext/XPathContext.xs,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -d -r1.29 -r1.30
--- XPathContext.xs 4 Apr 2003 09:08:47 -0000 1.29
+++ XPathContext.xs 4 Apr 2003 11:07:28 -0000 1.30
@@ -441,9 +441,9 @@
SV * pnode = &PL_sv_undef;
INIT:
xmlXPathContextPtr ctxt;
- CODE:
- if( items > 1 )
- pnode = ST(1);
+ CODE:
+ if( items > 1 )
+ pnode = ST(1);
ctxt = xmlXPathNewContext( NULL );
New(0, ctxt->user, sizeof(XPathContextData), XPathContextData);
@@ -451,9 +451,9 @@
croak("XPathContext: failed to allocate proxy object");
}
- if (SvOK(pnode)) {
- XPathContextDATA(ctxt)->node = SvREFCNT_inc(pnode);
- }
+ XPathContextDATA(ctxt)->node = pnode;
+ if (SvOK(pnode)) SvREFCNT_inc(pnode);
+
XPathContextDATA(ctxt)->lock = 0;
XPathContextDATA(ctxt)->pool = NULL;
@@ -478,7 +478,7 @@
if (ctxt) {
if (XPathContextDATA(ctxt) != NULL) {
if (XPathContextDATA(ctxt)->node != NULL &&
- SvOK(XPathContextDATA(ctxt)->node)) {
+ SvOK(XPathContextDATA(ctxt)->node)) {
SvREFCNT_dec(XPathContextDATA(ctxt)->node);
}
if (XPathContextDATA(ctxt)->pool != NULL &&
Index: Changes
===================================================================
RCS file: /cvsroot/perl-xml/XML-LibXML-XPathContext/Changes,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- Changes 4 Apr 2003 09:05:47 -0000 1.4
+++ Changes 4 Apr 2003 11:07:28 -0000 1.5
@@ -2,6 +2,10 @@
Revision history for Perl module XML::LibXML::XPathContext.
+Not in CVS
+
+* minor bug fix for new() without context node
+
0.02 Fri Apr 4 2003
* Added missing include xpathInternals.h what fixes problems with
|