You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xalan.apache.org by db...@apache.org on 2003/08/07 17:46:40 UTC

cvs commit: xml-xalan/c/src/xalanc/XPath FunctionNormalizeSpace.cpp

dbertoni    2003/08/07 08:46:40

  Modified:    c/src/xalanc/XPath FunctionNormalizeSpace.cpp
  Log:
  Make sure when optimizing, that we return a string.  Fixes Bugzilla 22218.
  
  Revision  Changes    Path
  1.2       +8 -1      xml-xalan/c/src/xalanc/XPath/FunctionNormalizeSpace.cpp
  
  Index: FunctionNormalizeSpace.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/src/xalanc/XPath/FunctionNormalizeSpace.cpp,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- FunctionNormalizeSpace.cpp	29 Jun 2003 03:58:00 -0000	1.1
  +++ FunctionNormalizeSpace.cpp	7 Aug 2003 15:46:40 -0000	1.2
  @@ -212,7 +212,14 @@
   
   	if (needsNormalization(theString) == false)
   	{
  -		return theArg;
  +		if (theArg->getType() == XObject::eTypeString)
  +		{
  +			return theArg;
  +		}
  +		else
  +		{
  +			return executionContext.getXObjectFactory().createStringAdapter(theArg);
  +		}
   	}
   	else
   	{
  
  
  

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