axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nand...@apache.org
Subject svn commit: r396802 - /webservices/axis2/trunk/c/modules/xml/parser/libxml2/libxml2_writer_wrapper.c
Date Tue, 25 Apr 2006 07:33:53 GMT
Author: nandika
Date: Tue Apr 25 00:33:52 2006
New Revision: 396802

URL: http://svn.apache.org/viewcvs?rev=396802&view=rev
Log:
get xml function changed to access xml output multiple times

Modified:
    webservices/axis2/trunk/c/modules/xml/parser/libxml2/libxml2_writer_wrapper.c

Modified: webservices/axis2/trunk/c/modules/xml/parser/libxml2/libxml2_writer_wrapper.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/xml/parser/libxml2/libxml2_writer_wrapper.c?rev=396802&r1=396801&r2=396802&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/xml/parser/libxml2/libxml2_writer_wrapper.c (original)
+++ webservices/axis2/trunk/c/modules/xml/parser/libxml2/libxml2_writer_wrapper.c Tue Apr
25 00:33:52 2006
@@ -735,7 +735,12 @@
     axis2_libxml2_writer_wrapper_impl_t *writer_impl = NULL;
     AXIS2_ENV_CHECK( env, AXIS2_FAILURE);
     writer_impl = AXIS2_INTF_TO_IMPL(writer);
-
+    
+    if(NULL != writer_impl->buffer)
+    {
+        xmlBufferFree(writer_impl->buffer);
+    	writer_impl->buffer = NULL;
+    }    	
     if(NULL != writer_impl->encoding)
     {
         AXIS2_FREE((*env)->allocator, writer_impl->encoding);
@@ -762,6 +767,8 @@
         writer->ops = NULL;
     }
     
+    
+    
     AXIS2_FREE((*env)->allocator, writer_impl);
     writer_impl = NULL;
     return AXIS2_SUCCESS;
@@ -1618,8 +1625,7 @@
                         strlen((const axis2_char_t*)(writer_impl->buffer->content))+1));
             sprintf(output, 
                     ((const axis2_char_t*)(writer_impl->buffer->content)));
-    	    xmlBufferFree(writer_impl->buffer);
-    	    writer_impl->buffer = NULL;
+    	   
         }
     }
     else if(writer_impl->writer_type == AXIS2_LIBXML2_WRITER_FILE)



Mime
View raw message