[openssl-project] inline functions

Richard Levitte levitte at openssl.org
Mon Jan 28 06:10:55 UTC 2019


On Mon, 28 Jan 2019 06:17:35 +0100,
Dr Paul Dale wrote:
> Richard wrote:
> 
>     Not really, since they are static inline. This is by design, that for any file you want to use
>     a safestack in, you just start with a DEFINE_ line. The mistake we did was to leave a few
>     common ones in the safestack header file. (same thing for lhash) 
> 
> Which means we’ve a compatibility issue.  The functions are in a public header, they can be used
> by any application.  We need to continue supporting such use.
> Asking a user to add a DEFINE_ line is API breaking.
> 
> I would be pro making such a change but we’d need to accept the consequences.

We have to accept consequences either way, either:

1. the surprise breakage if someone includes <openssl/safestack.h> but
   doesn't link with libcrypto, while compiling with
   -fkeep-inline-functions (explicitly or implicitly, depending on the
   compiler)

2. The controlled and documented change / breakage that they will have
   to either add those DEFINE lines where they need the functionality,
   or include another header file with common stack / lhash type
   implementations (with the caveat that they MUST link with libcrypto
   if they use those headers)

Cheers,
Richard

-- 
Richard Levitte         levitte at openssl.org
OpenSSL Project         http://www.openssl.org/~levitte/


More information about the openssl-project mailing list