Please refer to 
https://issues.apache.org/jira/browse/AXIS2C-1561

diff --git a/guththila/src/guththila_xml_writer.c b/guththila/src/guththila_xml_writer.c
index adc2389..8e68f6a 100644
--- a/guththila/src/guththila_xml_writer.c
+++ b/guththila/src/guththila_xml_writer.c
@@ -1755,6 +1755,11 @@
             guththila_stack_push(&wr->namesp, namesp, env);
             elem->name_sp_stack_no = GUTHTHILA_STACK_TOP_INDEX(wr->namesp);
         }
+        else 
+        {
+            AXIS2_FREE(env->allocator, namesp);
+            namesp = NULL;
+        }
 
 #ifndef GUTHTHILA_XML_WRITER_TOKEN
         elem->name = strdup(local_name);
diff --git a/src/core/deployment/dep_engine.c b/src/core/deployment/dep_engine.c
index 260b464..f285fb7 100644
--- a/src/core/deployment/dep_engine.c
+++ b/src/core/deployment/dep_engine.c
@@ -903,6 +903,7 @@
             "No memory. Allocation for Axis2 Configuration failed");
         return NULL;
     }
+    axis2_conf_set_dep_engine(dep_engine->conf, env, dep_engine);
     dep_engine->conf_builder = axis2_conf_builder_create_with_file_and_dep_engine_and_conf(env,
         dep_engine->conf_name, dep_engine, dep_engine->conf);
 
@@ -1789,7 +1790,7 @@
             module->handler_create_func_map);
     }
 
-    dep_engine->curr_file = NULL;
+    /*dep_engine->curr_file = NULL;*/
 
     return module_desc;
 }
diff --git a/src/core/engine/conf.c b/src/core/engine/conf.c
index 9efb102..ef5e941 100644
--- a/src/core/engine/conf.c
+++ b/src/core/engine/conf.c
@@ -1471,14 +1471,15 @@
 
         axutil_file_set_path(file, env, path);
         file_data = axis2_arch_file_data_create_with_type_and_file(env, AXIS2_MODULE, file);
-        if(!flag)
+        /*if(!flag)
         {
             dep_engine = axis2_dep_engine_create_with_repos_name(env, repos_path);
         }
         else
         {
             dep_engine = axis2_dep_engine_create_with_axis2_xml(env, axis2_xml);
-        }
+        }*/
+        dep_engine = conf->dep_engine;
 
         axis2_dep_engine_set_current_file_item(dep_engine, env, file_data);
 
@@ -1892,4 +1893,4 @@
     }
 
 	return AXIS2_FAILURE;
-}
\ No newline at end of file
+}