Apache OpenOffice (AOO) Bugzilla – Issue 96621
svtools: ambiguous && ||
Last modified: 2009-03-02 10:50:06 UTC
in svtools/source/svhtml/parhtml.cxx we have... if( RTL_TEXTENCODING_UCS2 == eEnc && (0xfe == (sal_uChar)pHeader[0] && 0xff == (sal_uChar)pHeader[1]) || (0xff == (sal_uChar)pHeader[0] && 0xfe == (sal_uChar)pHeader[1]) ) which means if( (RTL_TEXTENCODING_UCS2 == eEnc && (0xfe == (sal_uChar)pHeader[0] && 0xff == (sal_uChar)pHeader[1])) || (0xff == (sal_uChar)pHeader[0] && 0xfe == (sal_uChar)pHeader[1]) ) by operator precedence, I strongly suspect we mean if ( RTL_TEXTENCODING_UCS2 == eEnc && ( (0xfe == (sal_uChar)pHeader[0] && 0xff == (sal_uChar)pHeader[1]) || (0xff == (sal_uChar)pHeader[0] && 0xfe == (sal_uChar)pHeader[1]) ) ) so patch attached to do that
Created attachment 58327 [details] fix to do what I suspect we meant to say
cd->cmc: Thanks for the patch. Indeed, the old code looks broken. Patch accepted and added to CWS fwk95.
cd: Fixed, committed to CWS fwk95.
cd: Verified.
integrated DEV300_m40