From 309384f642e52da81cbaa5c61aa968e174fc654f Mon Sep 17 00:00:00 2001 From: nandika Date: Thu, 29 Apr 2010 05:57:28 +0000 Subject: code updated to fix crash issue git-svn-id: http://svn.apache.org/repos/asf/axis/axis2/c/core/trunk@939203 13f79535-47bb-0310-9956-ffa450edef68 --- axiom/src/om/om_stax_builder.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'axiom/src/om') diff --git a/axiom/src/om/om_stax_builder.c b/axiom/src/om/om_stax_builder.c index aca1878..052ce89 100644 --- a/axiom/src/om/om_stax_builder.c +++ b/axiom/src/om/om_stax_builder.c @@ -135,10 +135,13 @@ axiom_stax_builder_free_internal( axiom_stax_builder_t * om_builder, const axutil_env_t * env) { - axutil_hash_free(om_builder->declared_namespaces, env); - axiom_xml_reader_free(om_builder->parser, env); - axiom_document_free_self(om_builder->document, env); - AXIS2_FREE(env->allocator, om_builder); + if(om_builder) + { + axutil_hash_free(om_builder->declared_namespaces, env); + axiom_xml_reader_free(om_builder->parser, env); + axiom_document_free_self(om_builder->document, env); + AXIS2_FREE(env->allocator, om_builder); + } } /** -- cgit v1.1-32-gdbae