You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by ma...@apache.org on 2007/09/06 11:20:52 UTC
svn commit: r573194 -
/webservices/axis2/trunk/c/axiom/src/parser/libxml2/libxml2_reader_wrapper.c
Author: manjula
Date: Thu Sep 6 02:20:51 2007
New Revision: 573194
URL: http://svn.apache.org/viewvc?rev=573194&view=rev
Log:
Giving the ownership of container buffer to the parser
when xml_reaader creating from memory.
Modified:
webservices/axis2/trunk/c/axiom/src/parser/libxml2/libxml2_reader_wrapper.c
Modified: webservices/axis2/trunk/c/axiom/src/parser/libxml2/libxml2_reader_wrapper.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/axiom/src/parser/libxml2/libxml2_reader_wrapper.c?rev=573194&r1=573193&r2=573194&view=diff
==============================================================================
--- webservices/axis2/trunk/c/axiom/src/parser/libxml2/libxml2_reader_wrapper.c (original)
+++ webservices/axis2/trunk/c/axiom/src/parser/libxml2/libxml2_reader_wrapper.c Thu Sep 6 02:20:51 2007
@@ -152,6 +152,8 @@
AXIS2_CLOSE_INPUT_CALLBACK close_input_callback;
+ axis2_char_t *container;
+
}
axis2_libxml2_reader_wrapper_impl_t;
@@ -277,6 +279,7 @@
(void *)env);
wrapper_impl->current_event = -1;
wrapper_impl->ctx = NULL;
+ wrapper_impl->container = NULL;
axis2_libxml2_reader_wrapper_init_map(wrapper_impl);
@@ -336,6 +339,7 @@
(void *)env);
wrapper_impl->current_event = -1;
+ wrapper_impl->container = NULL;
axis2_libxml2_reader_wrapper_init_map(wrapper_impl);
@@ -398,6 +402,7 @@
}
wrapper_impl->current_event = -1;
+ wrapper_impl->container = (axis2_char_t *)container;
axis2_libxml2_reader_wrapper_init_map(wrapper_impl);
@@ -469,6 +474,11 @@
xmlTextReaderClose(AXIS2_INTF_TO_IMPL(parser)->reader);
xmlFreeTextReader(AXIS2_INTF_TO_IMPL(parser)->reader);
}
+
+ if (AXIS2_INTF_TO_IMPL(parser)->container)
+ {
+ AXIS2_FREE(env->allocator, AXIS2_INTF_TO_IMPL(parser)->container);
+ }
AXIS2_FREE(env->allocator, AXIS2_INTF_TO_IMPL(parser));
return;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org