Author: damitha
Date: Wed Jan 9 08:53:35 2008
New Revision: 610453
URL: http://svn.apache.org/viewvc?rev=610453&view=rev
Log:
Fixing memory leaks
Modified:
webservices/sandesha/trunk/c/config/module.xml
webservices/sandesha/trunk/c/include/sandesha2_ack_range.h
webservices/sandesha/trunk/c/include/sandesha2_constants.h
webservices/sandesha/trunk/c/samples/rm_echo_1_1/rm_echo_1_1.c
webservices/sandesha/trunk/c/samples/rm_echo_single_1_1/rm_echo_single_1_1.c
webservices/sandesha/trunk/c/samples/rm_ping_1_0/rm_ping_1_0.c
webservices/sandesha/trunk/c/src/handlers/sandesha2_out_handler.c
webservices/sandesha/trunk/c/src/msgprocessors/app_msg_processor.c
webservices/sandesha/trunk/c/src/transport/sandesha2_transport_sender.c
webservices/sandesha/trunk/c/src/util/ack_mgr.c
webservices/sandesha/trunk/c/src/util/msg_creator.c
webservices/sandesha/trunk/c/src/util/msg_init.c
webservices/sandesha/trunk/c/src/workers/sender_worker.c
webservices/sandesha/trunk/c/src/wsrm/ack_range.c
webservices/sandesha/trunk/c/src/wsrm/seq_ack.c
Modified: webservices/sandesha/trunk/c/config/module.xml
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/config/module.xml?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/config/module.xml (original)
+++ webservices/sandesha/trunk/c/config/module.xml Wed Jan 9 08:53:35 2008
@@ -84,6 +84,6 @@
<parameter name="MaxRetransCount" locked="false">10</parameter>
<parameter name="SenderSleepTime" locked="false">100000</parameter><!--In
micro seconds-->
<parameter name="InvokerSleepTime" locked="false">1</parameter>
- <parameter name="PollingWaitTime" locked="false">3</parameter>
+ <parameter name="PollingWaitTime" locked="false">2</parameter>
</module>
Modified: webservices/sandesha/trunk/c/include/sandesha2_ack_range.h
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/include/sandesha2_ack_range.h?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/include/sandesha2_ack_range.h (original)
+++ webservices/sandesha/trunk/c/include/sandesha2_ack_range.h Wed Jan 9
08:53:35 2008
@@ -47,6 +47,11 @@
sandesha2_iom_rm_element_t element;
};
+axis2_status_t AXIS2_CALL
+sandesha2_ack_range_free_void_arg(
+ void *ack_range,
+ const axutil_env_t *env);
+
AXIS2_EXTERN sandesha2_ack_range_t* AXIS2_CALL
sandesha2_ack_range_create(
const axutil_env_t *env,
Modified: webservices/sandesha/trunk/c/include/sandesha2_constants.h
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/include/sandesha2_constants.h?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/include/sandesha2_constants.h (original)
+++ webservices/sandesha/trunk/c/include/sandesha2_constants.h Wed Jan 9
08:53:35 2008
@@ -427,7 +427,7 @@
#define SANDESHA2_CLIENT_SLEEP_TIME 4 /* 32 16 */
- #define SANDESHA2_TERMINATE_DELAY 4 /* In seconds */
+ #define SANDESHA2_TERMINATE_DELAY 2 /* In seconds */
#define SANDESHA2_TEMP_SEQ_ID "uuid:tempID"
Modified: webservices/sandesha/trunk/c/samples/rm_echo_1_1/rm_echo_1_1.c
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/samples/rm_echo_1_1/rm_echo_1_1.c?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/samples/rm_echo_1_1/rm_echo_1_1.c (original)
+++ webservices/sandesha/trunk/c/samples/rm_echo_1_1/rm_echo_1_1.c Wed Jan 9
08:53:35 2008
@@ -31,7 +31,7 @@
#include <platforms/axutil_platform_auto_sense.h>
#include <ctype.h>
-#define SANDESHA2_MAX_COUNT 8
+#define SANDESHA2_MAX_COUNT 4
/* on_complete callback function */
axis2_status_t AXIS2_CALL
Modified:
webservices/sandesha/trunk/c/samples/rm_echo_single_1_1/rm_echo_single_1_1.c
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/samples/rm_echo_single_1_1/rm_echo_single_1_1.c?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
---
webservices/sandesha/trunk/c/samples/rm_echo_single_1_1/rm_echo_single_1_1.c
(original)
+++
webservices/sandesha/trunk/c/samples/rm_echo_single_1_1/rm_echo_single_1_1.c
Wed Jan 9 08:53:35 2008
@@ -30,7 +30,7 @@
#include <axis2_addr.h>
#include <ctype.h>
-#define SANDESHA2_MAX_COUNT 8
+#define SANDESHA2_SLEEP 8
/* on_complete callback function */
axis2_status_t AXIS2_CALL
@@ -183,11 +183,11 @@
if(status)
printf("\necho client single channel invoke SUCCESSFUL!\n");
payload = NULL;
- AXIS2_SLEEP(SANDESHA2_MAX_COUNT);
+ AXIS2_SLEEP(SANDESHA2_SLEEP);
sandesha2_client_terminate_seq_with_svc_client_and_seq_key(env,
svc_client,
seq_key);
- AXIS2_SLEEP(SANDESHA2_MAX_COUNT);
+ AXIS2_SLEEP(SANDESHA2_SLEEP);
if (svc_client)
{
axis2_svc_client_free(svc_client, env);
Modified: webservices/sandesha/trunk/c/samples/rm_ping_1_0/rm_ping_1_0.c
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/samples/rm_ping_1_0/rm_ping_1_0.c?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/samples/rm_ping_1_0/rm_ping_1_0.c (original)
+++ webservices/sandesha/trunk/c/samples/rm_ping_1_0/rm_ping_1_0.c Wed Jan 9
08:53:35 2008
@@ -23,7 +23,7 @@
#include <sandesha2_constants.h>
#include <ctype.h>
-#define MAX_COUNT 12
+#define SANDESHA2_SLEEP 12
axiom_node_t *
build_om_programatically(
@@ -139,14 +139,14 @@
if(status)
printf("\nping client invoke SUCCESSFUL!\n");
payload = NULL;
- /*AXIS2_SLEEP(MAX_COUNT);*/
+ /*AXIS2_SLEEP(SANDESHA2_SLEEP);*/
payload = build_om_programatically(env, "ping2", seq_key);
status = axis2_svc_client_send_robust(svc_client, env, payload);
if(status)
printf("\nping client invoke SUCCESSFUL!\n");
payload = NULL;
- /*AXIS2_SLEEP(MAX_COUNT);*/
+ /*AXIS2_SLEEP(SANDESHA2_SLEEP);*/
property = axutil_property_create_with_args(env, 0, 0, 0,
AXIS2_VALUE_TRUE);
axis2_options_set_property(options, env, "Sandesha2LastMessage",
@@ -162,7 +162,7 @@
/*This sleep is for wait the main thread until sandesha sends the
terminatesequence
*messages. */
- AXIS2_SLEEP(MAX_COUNT);
+ AXIS2_SLEEP(SANDESHA2_SLEEP);
if (svc_client)
{
Modified: webservices/sandesha/trunk/c/src/handlers/sandesha2_out_handler.c
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/src/handlers/sandesha2_out_handler.c?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/src/handlers/sandesha2_out_handler.c (original)
+++ webservices/sandesha/trunk/c/src/handlers/sandesha2_out_handler.c Wed Jan
9 08:53:35 2008
@@ -196,6 +196,8 @@
msg_processor = (sandesha2_msg_processor_t *)
sandesha2_app_msg_processor_create(env); /* rm intended msg */
}
+ if(req_rm_msg_ctx)
+ sandesha2_msg_ctx_free(req_rm_msg_ctx, env);
}
else if(!axis2_msg_ctx_get_server_side(msg_ctx, env))
{
@@ -217,6 +219,8 @@
{
/* Message should not be sent in an exception situation */
axis2_msg_ctx_set_paused(msg_ctx, env, AXIS2_TRUE);
+ if(rm_msg_ctx)
+ sandesha2_msg_ctx_free(rm_msg_ctx, env);
AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI,
"[sandesha2]Error in processing the message");
AXIS2_ERROR_SET(env->error, SANDESHA2_ERROR_CANNOT_PROCESS_MSG,
@@ -229,6 +233,8 @@
if(temp_prop)
axutil_property_set_value(temp_prop, env, axutil_strdup(
env,AXIS2_VALUE_FALSE));
+ if(rm_msg_ctx)
+ sandesha2_msg_ctx_free(rm_msg_ctx, env);
AXIS2_LOG_TRACE(env->log, AXIS2_LOG_SI,
"[sandesha2]Exit:sandesha2_out_handler_invoke");
return AXIS2_SUCCESS;
Modified: webservices/sandesha/trunk/c/src/msgprocessors/app_msg_processor.c
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/src/msgprocessors/app_msg_processor.c?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/src/msgprocessors/app_msg_processor.c
(original)
+++ webservices/sandesha/trunk/c/src/msgprocessors/app_msg_processor.c Wed Jan
9 08:53:35 2008
@@ -881,6 +881,8 @@
"[sandesha2]Sequence is NULL");
AXIS2_ERROR_SET(env->error, SANDESHA2_ERROR_SEQ_NOT_EXIST,
AXIS2_FAILURE);
+ if(req_rm_msg_ctx)
+ sandesha2_msg_ctx_free(req_rm_msg_ctx, env);
if(seq_prop_mgr)
sandesha2_seq_property_mgr_free(seq_prop_mgr, env);
if(create_seq_mgr)
@@ -897,6 +899,8 @@
{
AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI,
"[sandesha2]Sequence ID is NULL");
+ if(req_rm_msg_ctx)
+ sandesha2_msg_ctx_free(req_rm_msg_ctx, env);
if(seq_prop_mgr)
sandesha2_seq_property_mgr_free(seq_prop_mgr, env);
if(create_seq_mgr)
@@ -925,6 +929,8 @@
}
if(last_req_id)
AXIS2_FREE(env->allocator, last_req_id);
+ if(req_rm_msg_ctx)
+ sandesha2_msg_ctx_free(req_rm_msg_ctx, env);
}
else
{
@@ -1100,6 +1106,8 @@
sandesha2_seq_get_identifier(seq, env), env);
spec_ver_bean = sandesha2_seq_property_mgr_retrieve(seq_prop_mgr,
env, req_seq_id, SANDESHA2_SEQ_PROP_RM_SPEC_VERSION);
+ if(req_rm_msg_ctx)
+ sandesha2_msg_ctx_free(req_rm_msg_ctx, env);
if(!spec_ver_bean)
{
AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI,
@@ -1633,6 +1641,8 @@
AXIS2_ERROR_SET(env->error, SANDESHA2_ERROR_NULL_SEQ,
AXIS2_FAILURE);
if(rm_version)
AXIS2_FREE(env->allocator, rm_version);
+ if(req_rm_msg)
+ sandesha2_msg_ctx_free(req_rm_msg, env);
return AXIS2_FAILURE;
}
if(sandesha2_seq_get_last_msg(req_seq, env))
@@ -1641,6 +1651,8 @@
sandesha2_seq_set_last_msg(seq, env,
sandesha2_last_msg_create(env, rm_ns_val));
}
+ if(req_rm_msg)
+ sandesha2_msg_ctx_free(req_rm_msg, env);
}
else
{
@@ -1710,6 +1722,8 @@
AXIS2_FAILURE);
if(rm_version)
AXIS2_FREE(env->allocator, rm_version);
+ if(req_rm_msg_ctx)
+ sandesha2_msg_ctx_free(req_rm_msg_ctx, env);
return AXIS2_FAILURE;
}
incoming_seq_id = sandesha2_identifier_get_identifier(
@@ -1720,10 +1734,14 @@
"[sandesha2]Sequence ID is NULL");
if(rm_version)
AXIS2_FREE(env->allocator, rm_version);
+ if(req_rm_msg_ctx)
+ sandesha2_msg_ctx_free(req_rm_msg_ctx, env);
return AXIS2_FAILURE;
}
sandesha2_msg_creator_add_ack_msg(env, rm_msg_ctx, incoming_seq_id,
seq_prop_mgr);
+ if(req_rm_msg_ctx)
+ sandesha2_msg_ctx_free(req_rm_msg_ctx, env);
engine = axis2_engine_create(env, axis2_msg_ctx_get_conf_ctx(msg_ctx,
env));
return axis2_engine_resume_send(engine, env, msg_ctx);
Modified:
webservices/sandesha/trunk/c/src/transport/sandesha2_transport_sender.c
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/src/transport/sandesha2_transport_sender.c?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/src/transport/sandesha2_transport_sender.c
(original)
+++ webservices/sandesha/trunk/c/src/transport/sandesha2_transport_sender.c Wed
Jan 9 08:53:35 2008
@@ -147,6 +147,7 @@
{
axutil_property_t *property = NULL;
axis2_transport_out_desc_t *out_desc = NULL;
+ axis2_transport_out_desc_t *temp_out_desc = NULL;
axis2_char_t *key = NULL;
axis2_conf_ctx_t *conf_ctx = NULL;
axis2_conf_t *conf = NULL;
@@ -163,6 +164,9 @@
if(NULL == property || NULL == axutil_property_get_value(property, env))
return AXIS2_FAILURE;
out_desc = axutil_property_get_value(property, env);
+ temp_out_desc = axis2_msg_ctx_get_transport_out_desc(msg_ctx, env);
+ if(temp_out_desc)
+ axis2_transport_out_desc_free(temp_out_desc, env);
axis2_msg_ctx_set_transport_out_desc(msg_ctx, env, out_desc);
property = axis2_msg_ctx_get_property(msg_ctx, env,
Modified: webservices/sandesha/trunk/c/src/util/ack_mgr.c
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/src/util/ack_mgr.c?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/src/util/ack_mgr.c (original)
+++ webservices/sandesha/trunk/c/src/util/ack_mgr.c Wed Jan 9 08:53:35 2008
@@ -271,7 +271,11 @@
break;
}
if(sandesha2_ack_range_get_upper_value(ack_range, env) >= last_msg_no)
+ {
+ if(hash)
+ axutil_hash_free(hash, env);
return AXIS2_TRUE;
+ }
start = sandesha2_ack_range_get_upper_value(ack_range, env) + 1;
}
if(hash)
Modified: webservices/sandesha/trunk/c/src/util/msg_creator.c
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/src/util/msg_creator.c?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/src/util/msg_creator.c (original)
+++ webservices/sandesha/trunk/c/src/util/msg_creator.c Wed Jan 9 08:53:35 2008
@@ -619,6 +619,7 @@
}
temp_msg_id = axutil_uuid_gen(env);
axis2_msg_ctx_set_message_id(terminate_seq_msg_ctx, env, temp_msg_id);
+ AXIS2_FREE(env->allocator, temp_msg_id);
temp_envelope = sandesha2_msg_ctx_get_soap_envelope(ref_rm_msg, env);
soap_version = sandesha2_utils_get_soap_version(env, temp_envelope);
envelope = axiom_soap_envelope_create_default_soap_envelope(env,
soap_version);
Modified: webservices/sandesha/trunk/c/src/util/msg_init.c
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/src/util/msg_init.c?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/src/util/msg_init.c (original)
+++ webservices/sandesha/trunk/c/src/util/msg_init.c Wed Jan 9 08:53:35 2008
@@ -441,8 +441,8 @@
env, seq_id, SANDESHA2_SEQ_PROP_INTERNAL_SEQ_ID);
if(internal_seq_id_bean)
{
- prop_key = sandesha2_seq_property_bean_get_value(
- internal_seq_id_bean, env);
+ prop_key = axutil_strdup(env,
sandesha2_seq_property_bean_get_value(
+ internal_seq_id_bean, env));
}
}
rm_ns = sandesha2_msg_ctx_get_rm_ns_val(rm_msg_ctx, env);
@@ -453,6 +453,11 @@
spec_version = sandesha2_utils_get_rm_version(env, prop_key,
seq_prop_mgr);
+ if(prop_key)
+ {
+ AXIS2_FREE(env->allocator, prop_key);
+ prop_key = NULL;
+ }
if(spec_version)
{
seq_rm_ns = sandesha2_spec_specific_consts_get_rm_ns_val(env,
@@ -473,6 +478,8 @@
}
}
}
+ if(prop_key)
+ AXIS2_FREE(env->allocator, prop_key);
if(seq_prop_mgr)
sandesha2_seq_property_mgr_free(seq_prop_mgr, env);
AXIS2_LOG_TRACE(env->log, AXIS2_LOG_SI,
Modified: webservices/sandesha/trunk/c/src/workers/sender_worker.c
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/src/workers/sender_worker.c?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/src/workers/sender_worker.c (original)
+++ webservices/sandesha/trunk/c/src/workers/sender_worker.c Wed Jan 9
08:53:35 2008
@@ -516,7 +516,9 @@
res_envelope))
axis2_engine_receive_fault(engine, env, res_msg_ctx);
else
- axis2_engine_receive(engine, env, res_msg_ctx);
+ axis2_engine_receive(engine, env, res_msg_ctx);
+ if(engine)
+ axis2_engine_free(engine, env);
}
/* To avoid a second passing through incoming handlers at op_client*/
property = axutil_property_create_with_args(env, 0, 0, 0,
AXIS2_VALUE_TRUE);
Modified: webservices/sandesha/trunk/c/src/wsrm/ack_range.c
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/src/wsrm/ack_range.c?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/src/wsrm/ack_range.c (original)
+++ webservices/sandesha/trunk/c/src/wsrm/ack_range.c Wed Jan 9 08:53:35 2008
@@ -119,10 +119,21 @@
return &(ack_range_impl->ack_range);
}
+axis2_status_t AXIS2_CALL
+sandesha2_ack_range_free_void_arg(
+ void *ack_range,
+ const axutil_env_t *env)
+{
+ sandesha2_iom_rm_element_t *ack_range_l = NULL;
+
+ ack_range_l = (sandesha2_iom_rm_element_t *) ack_range;
+ return sandesha2_ack_range_free(ack_range_l, env);
+}
axis2_status_t AXIS2_CALL
-sandesha2_ack_range_free (sandesha2_iom_rm_element_t *ack_range,
- const axutil_env_t *env)
+sandesha2_ack_range_free (
+ sandesha2_iom_rm_element_t *ack_range,
+ const axutil_env_t *env)
{
sandesha2_ack_range_impl_t *ack_range_impl = NULL;
AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
Modified: webservices/sandesha/trunk/c/src/wsrm/seq_ack.c
URL:
http://svn.apache.org/viewvc/webservices/sandesha/trunk/c/src/wsrm/seq_ack.c?rev=610453&r1=610452&r2=610453&view=diff
==============================================================================
--- webservices/sandesha/trunk/c/src/wsrm/seq_ack.c (original)
+++ webservices/sandesha/trunk/c/src/wsrm/seq_ack.c Wed Jan 9 08:53:35 2008
@@ -79,7 +79,6 @@
sandesha2_seq_ack_create(const axutil_env_t *env, axis2_char_t *ns_val)
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
- AXIS2_ENV_CHECK(env, NULL);
AXIS2_PARAM_CHECK(env->error, ns_val, NULL);
if(AXIS2_FALSE == sandesha2_seq_ack_is_namespace_supported(
@@ -162,7 +161,6 @@
const axutil_env_t *env)
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
- AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
if(NULL != seq_ack_impl->ns_val)
@@ -200,7 +198,6 @@
const axutil_env_t *env)
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
- AXIS2_ENV_CHECK(env, NULL);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
return seq_ack_impl->ns_val;
@@ -223,7 +220,6 @@
axiom_namespace_t *rm_ns = NULL;
axis2_char_t *prefix = NULL;
- AXIS2_ENV_CHECK(env, NULL);
AXIS2_PARAM_CHECK(env->error, sa_node, NULL);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
@@ -252,6 +248,8 @@
}
ack_iter = axiom_element_get_children_with_qname(sa_part, env,
ack_range_qname, sa_node);
+ if(ack_range_qname)
+ axutil_qname_free(ack_range_qname, env);
if(!ack_iter)
{
return NULL;
@@ -375,7 +373,6 @@
int i = 0;
axis2_char_t *rm_spec_ver = NULL;
- AXIS2_ENV_CHECK(env, NULL);
AXIS2_PARAM_CHECK(env->error, om_node, NULL);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
@@ -477,7 +474,6 @@
const axutil_env_t *env, axis2_char_t *namespace)
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
- AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
if(0 == axutil_strcmp(namespace, SANDESHA2_SPEC_2005_02_NS_URI))
@@ -497,7 +493,6 @@
const axutil_env_t *env)
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
- AXIS2_ENV_CHECK(env, NULL);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
@@ -511,7 +506,6 @@
sandesha2_identifier_t *identifier)
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
- AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
seq_ack_impl->identifier = identifier;
@@ -524,7 +518,6 @@
const axutil_env_t *env)
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
- AXIS2_ENV_CHECK(env, NULL);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
@@ -538,7 +531,6 @@
sandesha2_ack_final_t *ack_final)
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
- AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
seq_ack_impl->ack_final = ack_final;
@@ -551,7 +543,6 @@
const axutil_env_t *env)
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
- AXIS2_ENV_CHECK(env, NULL);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
@@ -565,7 +556,6 @@
sandesha2_ack_range_t *ack_range)
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
- AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
axutil_array_list_add(seq_ack_impl->ack_range_list, env, ack_range);
@@ -578,7 +568,6 @@
const axutil_env_t *env)
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
- AXIS2_ENV_CHECK(env, AXIS2_FALSE);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
return seq_ack_impl->must_understand;
@@ -591,8 +580,6 @@
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
- AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
-
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
seq_ack_impl->must_understand = mu;
return AXIS2_SUCCESS;
@@ -602,13 +589,13 @@
static axis2_status_t AXIS2_CALL
sandesha2_seq_ack_to_soap_env(
sandesha2_iom_rm_part_t *seq_ack,
- const axutil_env_t *env, axiom_soap_envelope_t *envelope)
+ const axutil_env_t *env,
+ axiom_soap_envelope_t *envelope)
{
sandesha2_seq_ack_impl_t *seq_ack_impl = NULL;
axiom_soap_header_t *soap_header = NULL;
axutil_qname_t *seq_ack_qname = NULL;
- AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
AXIS2_PARAM_CHECK(env->error, envelope, AXIS2_FAILURE);
seq_ack_impl = SANDESHA2_INTF_TO_IMPL(seq_ack);
@@ -616,16 +603,17 @@
/**
* Remove if old exists
*/
- seq_ack_qname = axutil_qname_create(env,
- SANDESHA2_WSRM_COMMON_SEQ_ACK,
- seq_ack_impl->ns_val, NULL);
- if(NULL == seq_ack_qname)
+ seq_ack_qname = axutil_qname_create(env, SANDESHA2_WSRM_COMMON_SEQ_ACK,
+ seq_ack_impl->ns_val, NULL);
+ if(!seq_ack_qname)
{
return AXIS2_FAILURE;
}
axiom_soap_header_remove_header_block(soap_header, env, seq_ack_qname);
+ if(seq_ack_qname)
+ axutil_qname_free(seq_ack_qname, env);
sandesha2_seq_ack_to_om_node((sandesha2_iom_rm_element_t*)seq_ack, env,
- soap_header);
+ soap_header);
return AXIS2_SUCCESS;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]