Apache OpenOffice (AOO) Bugzilla – Issue 9337
C++: & and l-value
Last modified: 2013-08-07 14:43:23 UTC
This is from: http://www.openoffice.org/servlets/ReadMsg?msgId=454168&listName=dev see also Stephan's response http://www.openoffice.org/servlets/ReadMsg?msgId=454663&listName=dev Hi, while compiling OOo 1.0.1 on Sun Solaris 8 with Forte C++ update 2 (with all patches) it issued this error while compiling sw/source/ui/misc/glosdoc.cxx: "/oo/Build/oo_1.0.1_src/sw/source/ui/misc/glosdoc.cxx", line 164: Error: The "&" operator can only be applied to a variable or other l-value. GCC (2.95 on Solaris) and 3.0.4 (on SuSE Linux) compile this without even warning me. I tend to agree that Forte is right here so I applied this change to that file: --- sw/source/ui/misc/glosdoc.cxx~ Tue Nov 12 02:22:16 2002 +++ sw/source/ui/misc/glosdoc.cxx Tue Nov 12 02:22:16 2002 @@ -158,10 +158,11 @@ if( !bOk ) { + String sExt (SwGlossaries::GetExtension()); //generate generic name utl::TempFile aTemp( String::CreateFromAscii( RTL_CONSTASCII_STRINGPARAM( "group" )), - &SwGlossaries::GetExtension(), + &sExt, &rNewFilePath ); aTemp.EnableKillingFile();
Confirmed by Stephan.
Created attachment 3674 [details] suggested fix as a patch
JA->AMA: reassigned to the project owner
Ok, accepted.
FME: Has already been fixed in sw/source/ui/misc/glosdoc.cxx rev. 1.13
OD (25.02.2003): reopen for verify and QA
OD->SBA (25.02.2003): Fix is integrated in OOo_srx644_m1. Please verify and close this issue.
Set to fixed.
Set to verified.
Closed.