You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by na...@apache.org on 2008/06/03 10:33:02 UTC
svn commit: r662696 -
/webservices/axis2/trunk/c/src/core/transport/http/common/http_header.c
Author: nandika
Date: Tue Jun 3 01:33:01 2008
New Revision: 662696
URL: http://svn.apache.org/viewvc?rev=662696&view=rev
Log:
potential invalid read fixed
Modified:
webservices/axis2/trunk/c/src/core/transport/http/common/http_header.c
Modified: webservices/axis2/trunk/c/src/core/transport/http/common/http_header.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/src/core/transport/http/common/http_header.c?rev=662696&r1=662695&r2=662696&view=diff
==============================================================================
--- webservices/axis2/trunk/c/src/core/transport/http/common/http_header.c (original)
+++ webservices/axis2/trunk/c/src/core/transport/http/common/http_header.c Tue Jun 3 01:33:01 2008
@@ -71,7 +71,7 @@
return NULL;
}
/* remove trailing \r\n */
- if (AXIS2_RETURN == tmp_str[axutil_strlen(tmp_str) - 2])
+ if ((axutil_strlen(tmp_str) >= 2) && (AXIS2_RETURN == tmp_str[axutil_strlen(tmp_str) - 2]))
{
tmp_str[axutil_strlen(tmp_str) - 2] = AXIS2_ESC_NULL;
}