Apache OpenOffice (AOO) Bugzilla – Issue 14863
return type mismatch - return by value assigned to reference
Last modified: 2004-02-15 07:31:51 UTC
gcc 3.3 now provides error messages when there are return type mismatches such as when a method returns an object by value that is assigned to a reference which is a bug since the reference points to a temporary variable created to hold the return by value. An occurrence of this type occurred here see ... (fixme?) Please evaluate that line and fix the code in question to prevent the bug if needed. xmloff/source/core/nmspmap.cxx @@ -256,7 sQName.append ( (*aIter).second->sPrefix); sQName.append ( sal_Unicode(':') ); sQName.append ( rLocalName ); (fixme?) OUString *pString = new OUString ( rLocalName ), &rString = sQName.makeStringAndClear(); const_cast < QNameCache * > (&aQNameCache)->operator[] ( QNamePair ( nKey, pString ) ) = rString; return rString; } xmloff/source/text/XMLChangeImportContext.cxx @@ -133,7 // prepare parameters UniReference<XMLTextImportHelper> rHelper = GetImport().GetTextImport(); (fixme?) OUString& rID = xAttrList->getValueByIndex(nAttr); // call for bStart and bEnd (may both be true) if (bIsStart) xmloff/source/text/XMLChangedRegionImportContext.cxx @@ -137,7 GetKeyByAttrName( xAttrList->getNameByIndex(nAttr), &sLocalName ); (fixme?) OUString& rValue = xAttrList->getValueByIndex(nAttr); if ( XML_NAMESPACE_TEXT == nPrefix ) { if( IsXMLToken( sLocalName, XML_ID ) ) xmloff/source/text/txtflde.cxx @@ -1506,7 case FIELD_ID_DATABASE_DISPLAY: { // get database, table and column name from field master (fixme?) Reference<XPropertySet> & xMaster = GetMasterPropertySet(rTextField); ProcessString(XML_DATABASE_NAME, GetStringProperty(sPropertyDataBaseName, xMaster)); ProcessString(XML_TABLE_NAME,
re set prio.
P3 seems to be more apropriate, because the code should be fixed until the 1.1, but does not cause a real damage.
dvo: Fixed in CWS sw016. All fixes as indicated by the (fixme?) marks in the bug description.
dvo: Verified in sw016. dvo->khendricks: Please verify & close issue after fixes are integrated into main tree.
.
dvo->khendricks: Please verify & close issue after fixes have been integrated into main tree.
According to Daniel, nothing to test for QA.
Set to verified in CWS sw016. -> Kevin: Please check and close after CWS sw016 got integrated. Thx.
close issue