axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sam...@apache.org
Subject svn commit: r388466 - /webservices/axis2/trunk/c/modules/core/description/param.c
Date Fri, 24 Mar 2006 09:05:10 GMT
Author: samisa
Date: Fri Mar 24 01:05:10 2006
New Revision: 388466

URL: http://svn.apache.org/viewcvs?rev=388466&view=rev
Log:
Fixed param value free

Modified:
    webservices/axis2/trunk/c/modules/core/description/param.c

Modified: webservices/axis2/trunk/c/modules/core/description/param.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/description/param.c?rev=388466&r1=388465&r2=388466&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/description/param.c (original)
+++ webservices/axis2/trunk/c/modules/core/description/param.c Fri Mar 24 01:05:10 2006
@@ -175,8 +175,21 @@
 							axis2_env_t **env, 
 							void *value)
 {
+    void *param_value = NULL;
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
     
+    param_value = axis2_param_get_value(param, env);
+    if(param_value)
+    {
+        if(param->ops && param->ops->value_free)
+        { 
+            param->ops->value_free(param_value, env);
+        }
+        else /* we assume that param value is axis2_char_t* */
+        {
+            AXIS2_FREE((*env)->allocator, param_value);
+        }
+    }
     AXIS2_INTF_TO_IMPL(param)->value = value;
     return AXIS2_SUCCESS;
 }



Mime
View raw message