openoffice-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Patricia Shanahan <p...@acm.org>
Subject Re: compiler warnings when building OpenOffice
Date Sun, 04 Sep 2016 22:45:57 GMT
On 9/1/2016 4:00 PM, Don Lewis wrote:
> On  1 Sep, Patricia Shanahan wrote:
>> I need a problem to work on. Would you like me to take a particular
>> compiler warning and try to sort it out?
>
> Here is one:
>
> /wrkdirs/usr/ports/editors/openoffice-devel2/work/aoo-4.2.0/main/solver/420/unxfbsdx.pro/inc/osl/diagnose.hxx:65:25:
warning: 'osl_detail_ObjectRegistry_getMutex' has C-linkage specified, but returns user-defined
type '::osl::Mutex &' which is incompatible with C [-Wreturn-type-c-linkage]
>
> In sal/inc/osl/diagnose.hxx,
>   ::osl::Mutex & SAL_CALL osl_detail_ObjectRegistry_getMutex()
> is declared inside an extern "C" block, so it should have C linkage, but
> it is returning a reference, which is a C++ thing.
>
> The obvious fix would seem to be to move it out of the extern "C" block,
> but I don't know what to do about the SAL_THROW_EXTERN_C() part of the
> declaration.

I have compiled and done some basic tests with the declaration simply 
moved out of the extern "C" block, and it did not appear to cause any 
problems. I'll look into SAL_THROW_EXTERN_C next.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
For additional commands, e-mail: dev-help@openoffice.apache.org


Mime
View raw message