[PATCH 3/3] Use latest <semaphore.h> from FreeBSD for RTEMS
Corinna Vinschen
vinschen@redhat.com
Wed Mar 11 12:46:00 GMT 2015
On Mar 11 13:35, Corinna Vinschen wrote:
> On Mar 11 13:17, Sebastian Huber wrote:
> > >> +#define SEM_VALUE_MAX (__INT_MAX__ * 2U + 1U)
> > >
> > > Should the definition of SEM_VALUE_MAX be __BSD_VISIBLE? It's not a
> > > definition required or even mentioned in POSIX.
> >
> > We have a {SEM_VALUE_MAX} here:
> >
> > http://pubs.opengroup.org/onlinepubs/009695399/functions/sem_open.html
> >
> > Is this not a define? In FreeBSD it is not covered by __BSD_VISIBLE.
>
> This is weird. SEM_VALUE_MAX is not mentioned in
> http://pubs.opengroup.org/onlinepubs/009695399/basedefs/semaphore.h.html
>
> Is that a bug in the specification?
SUSv4 defines SEM_VALUE_MAX to be in limits.h. That's where we
have it in Cygwin, too. There's also the definition of SEM_VALUE_MAX
for RTEMS in libc/sys/rtems/include/limits.h.
It seems defining it additionally in semaphore.h is not quite correct.
It also contradicts the value from your limits.h (32767).
Corinna
--
Corinna Vinschen
Cygwin Maintainer
Red Hat
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/newlib/attachments/20150311/0bf20516/attachment.sig>
More information about the Newlib
mailing list