axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sen...@apache.org
Subject svn commit: r630634 - /webservices/axis2/trunk/c/util/src/string.c
Date Sun, 24 Feb 2008 16:37:47 GMT
Author: senaka
Date: Sun Feb 24 08:37:47 2008
New Revision: 630634

URL: http://svn.apache.org/viewvc?rev=630634&view=rev
Log:
Fixing bug in strrtrim

Modified:
    webservices/axis2/trunk/c/util/src/string.c

Modified: webservices/axis2/trunk/c/util/src/string.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/src/string.c?rev=630634&r1=630633&r2=630634&view=diff
==============================================================================
--- webservices/axis2/trunk/c/util/src/string.c (original)
+++ webservices/axis2/trunk/c/util/src/string.c Sun Feb 24 08:37:47 2008
@@ -665,17 +665,20 @@
 AXIS2_EXTERN axis2_char_t *AXIS2_CALL
 axutil_strrtrim(
     const axutil_env_t * env,
-    const axis2_char_t * _s,
+    const axis2_char_t * _in,
     const axis2_char_t * _trim)
 {
     axis2_char_t *__tail;
+    axis2_char_t *_s = NULL;
     axis2_char_t *ret = NULL;
 
+    _s = axutil_strdup(env, _in);
+
     if (!_s)
     {
         return NULL;
     }
-    __tail = ((axis2_char_t *) _s) + axutil_strlen(_s);
+    __tail = _s + axutil_strlen(_s);
     if (!_trim)
     {
         _trim = " \t\n\r";
@@ -684,7 +687,7 @@
     {
         if (!strchr(_trim, *__tail))
         {
-            ret = (axis2_char_t *) axutil_strdup(env, _s);
+            ret = _s;
             break;
         }
         *__tail = 0;



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org


Mime
View raw message