From bf5e74bbe75e4918921ca56683d77403d37f09d5 Mon Sep 17 00:00:00 2001 From: PeiYong Zhang <peiyongz@apache.org> Date: Mon, 11 Mar 2002 21:08:23 +0000 Subject: [PATCH] Bug#7000: fix to corrupted URL, patch from kent@iastate.edu (Kent) git-svn-id: https://svn.apache.org/repos/asf/xerces/c/trunk@173570 13f79535-47bb-0310-9956-ffa450edef68 --- .../NetAccessors/Socket/UnixHTTPURLInputStream.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/xercesc/util/NetAccessors/Socket/UnixHTTPURLInputStream.cpp b/src/xercesc/util/NetAccessors/Socket/UnixHTTPURLInputStream.cpp index 02022dc3c..23092ebb6 100644 --- a/src/xercesc/util/NetAccessors/Socket/UnixHTTPURLInputStream.cpp +++ b/src/xercesc/util/NetAccessors/Socket/UnixHTTPURLInputStream.cpp @@ -56,8 +56,11 @@ /* * $Log$ - * Revision 1.1 2002/02/01 22:22:23 peiyongz - * Initial revision + * Revision 1.2 2002/03/11 21:08:23 peiyongz + * Bug#7000: fix to corrupted URL, patch from kent@iastate.edu (Kent) + * + * Revision 1.1.1.1 2002/02/01 22:22:23 peiyongz + * sane_include * * Revision 1.7 2001/09/04 17:53:09 peiyongz * Bugzilla# 3170: patch from Kevin Philips to handle Query in XMLURL. @@ -196,7 +199,9 @@ UnixHTTPURLInputStream::UnixHTTPURLInputStream(const XMLURL& urlSource) if (queryAsCharStar != 0) { - fBuffer[strlen(fBuffer)] = chQuestion; + size_t n = strlen(fBuffer); + fBuffer[n] = chQuestion; + fBuffer[n+1] = chNull; strcat(fBuffer, queryAsCharStar); } -- GitLab