[openssl-users] Dealing with RFC2553 and RFC3493 where NI_MAXHOST and NI_MAXSERV no longer exist

Dennis Clarke dclarke at blastwave.org
Tue Jan 22 20:54:28 UTC 2019


On 1/22/19 2:58 PM, Kurt Roeckx wrote:
> On Fri, Jan 18, 2019 at 06:40:05PM -0500, Dennis Clarke wrote:
>> On 1/18/19 1:53 AM, Dennis Clarke wrote:
>>>
>>> Going in circles trying to compile 1.1.1a with strict C99 and no
>>> optimizations and with a ready to debug and single step resultant
>>> library.
>>
>> Ignore all this.  Thou shalt not C99 here.
> 
> Our code base is currently C89/C90, with some extenions, but things
> like gcc default to something like "gnu99", "gnu11" or "gnu17".
> And we actually make use of some of those extensions not in C89.

I tend to look at anything 'gnu-foo' as clearly non-standard but still
very very popular and thus defacto standard.  Whatever that means. :-)

> 
> The ones I know about:
> - asm(): Most of those should go away if you define PEDANTIC.

No need with the Oracle Studio compilers.  Just use c99 and strict
CFLAGS and watch it utter the endless complaints.

>   I think the only exception is code we compile when gcc is used.
> - strdup() and strcasecmp() which are in POSIX, but not in C

Yep .. that thing.

> - Setting the mutex type, which seems to be UNIX98 or XOPEN2K8
> - isascii: XOPEN
> - usleep: Was in POSIX, has been replaced by nanosleep
> - long long: Since C99
> 
> Then we also use things like int32_t, but define the type ourself
> if the compiler is C89. We detect C11 support for atomics.
> 
> Anyway, if you have a good patch to remove things that are no
> longer in a standard, and it also works with older systems, I suggest
> submit a patch.

I think that Rich Salz has already weighed in on this battle and the
code base is C89 clean.  A leap to C99 compliance may not be on anyones
horizon at all and I am not sure how much work would be needed. Curious
to look at it however.

Dennis Clarke

ps: see excellent email from Michael Wojcik Fri Jan 18 01:25:10 UTC 2019
     where "strcasecmp is a heresy" :

https://mta.openssl.org/pipermail/openssl-users/2019-January/009735.html


More information about the openssl-users mailing list