Kaydet (Commit) 2eeb8010 authored tarafından Oliver-Rainer Wittmann's avatar Oliver-Rainer Wittmann

#119446# - method <SwWW8ImplReader::Read_Field(..)> - correct condition for…

#119446# - method <SwWW8ImplReader::Read_Field(..)> - correct condition for fields containing '.' or '/'

Found by: Yan Ji
Patch by: zjchen
Review by: Oliver
üst efc6346e
......@@ -987,9 +987,16 @@ long SwWW8ImplReader::Read_Field(WW8PLCFManResult* pRes)
pStrm->Seek( nOldPos );
//#124725# field codes which contain '/' or '.' are not displayed in WinWord
if (!aStr.EqualsAscii(" ADDIN", 0, 6) &&
(aStr.Search('.') != STRING_NOTFOUND ||
aStr.Search('/') != STRING_NOTFOUND))
// skip if it is formula field or found space before. see #i119446, #i119585.
const xub_StrLen nDotPos = aStr.Search('.');
const xub_StrLen nSlashPos = aStr.Search('/');
xub_StrLen nSpacePos = aStr.Search( ' ', 1 );
if ( nSpacePos == STRING_NOTFOUND )
nSpacePos = aStr.Len();
if ( !( aStr.EqualsAscii( "=", 1, 1 ) ) &&
((( nDotPos != STRING_NOTFOUND ) && ( nDotPos < nSpacePos )) ||
(( nSlashPos != STRING_NOTFOUND ) && ( nSlashPos < nSpacePos ))))
return aF.nLen;
else
return aF.nLen - aF.nLRes - 1; // so viele ueberlesen, das Resultfeld
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment