Re: reentrant functions

2004-04-20 Thread Yitzchak Scott-Thoennes
On Tue, Apr 20, 2004 at 01:16:24PM +0200, Corinna Vinschen <[EMAIL PROTECTED]> wrote: > On Apr 20 01:37, Yitzchak Scott-Thoennes wrote: > > As of the 20040416 snapsnot, ttyname_r seems to be exported, but the > > prototype is missing from unistd.h. > > I've added a prototype to unistd.h. Thanks.

Re: reentrant functions

2004-04-20 Thread Corinna Vinschen
On Apr 20 01:37, Yitzchak Scott-Thoennes wrote: > As of the 20040416 snapsnot, ttyname_r seems to be exported, but the > prototype is missing from unistd.h. I've added a prototype to unistd.h. Thanks, Corinna -- Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Co-

Re: reentrant functions

2004-04-20 Thread Yitzchak Scott-Thoennes
On Fri, Apr 16, 2004 at 09:18:24PM +0200, Bas van Gompel wrote: > Op Wed, 14 Apr 2004 11:12:14 +0200 > schreef Corinna Vinschen: > : > ttyname_r appears to be implemented only for linux > : > (in newlib/libc/sys/linux/ttyname_r.c). > : > > : > ctime_r, asctime_r, getpwnam_r, getpwuid_r, gmtime_r, l

Re: reentrant functions

2004-04-18 Thread Bas van Gompel
Op Fri, 16 Apr 2004 23:57:08 +0200 schreef Corinna Vinschen in <[EMAIL PROTECTED]>: : On Apr 16 21:18, Bas van Gompel wrote: [implementing getgrgid_r, getgrnam_r, getlogin_r and readdir_r] : > : > I'm willing... : > : > I've got most of readdir_r implemented, testing... : > I'll look at the other

Re: reentrant functions

2004-04-16 Thread Corinna Vinschen
On Apr 16 21:18, Bas van Gompel wrote: > Op Wed, 14 Apr 2004 11:12:14 +0200 > schreef Corinna Vinschen > : I'm also positivly hoping for volunteers implementing getgrgid_r, > : getgrnam_r, getlogin_r and readdir_r. > > I'm willing... > > I've got most of readdir_r implemented, testing... > I'l

Re: reentrant functions

2004-04-16 Thread Bas van Gompel
Op Wed, 14 Apr 2004 11:12:14 +0200 schreef Corinna Vinschen in <[EMAIL PROTECTED]>: : I just had a look into this again. : : On Apr 9 19:18, Bas van Gompel wrote: : > Ok then, another try... : > : > Candidates getgrgid_r, getgrnam_r and getlogin_r are not : > implemented. : : I'm wondering a b

Re: reentrant functions

2004-04-14 Thread Corinna Vinschen
I just had a look into this again. On Apr 9 19:18, Bas van Gompel wrote: > Ok then, another try... > > Candidates getgrgid_r, getgrnam_r and getlogin_r are not > implemented. I'm wondering a bit about getgrgid_r and getgrnam_r. As you noted below, we have getpwnam_r and getpwuid_r so why did n

Re: reentrant functions

2004-04-12 Thread Oleg Ostrozhansky
Wouldn't you just want to export all _*_r symbols listed in the "Reentrancy" section of "info libc", which are: _Equivalent for errno variable:_ _errno_r _Locale functions:_ _localeconv_r _setlocale_r _Equivalents for stdio variables:_ _s

Re: reentrant functions

2004-04-09 Thread Bas van Gompel
Op Fri, 9 Apr 2004 10:45:38 -0400 schreef Christopher Faylor in <[EMAIL PROTECTED]>: [...] : newlib does produce a 'rand_r' function, so Buzz's list is incomplete. FWIW, I only listed the __r functions, not the _r functions. L8r, Buzz. -- ) | | ---/ ---/ Yes, this | This message consists

Re: reentrant functions

2004-04-09 Thread Bas van Gompel
Op Fri, 9 Apr 2004 00:01:56 -0400 schreef Christopher Faylor in <[EMAIL PROTECTED]>: : On Fri, Apr 09, 2004 at 04:33:26AM +0200, Bas van Gompel wrote: [don't export _r functions which are only in newlib and in no UNIX] : > Yeah, sure. But this means I won't be able to help any further : > with t

RE: reentrant functions

2004-04-09 Thread Richard Campbell
Corrected, missed the gammas, although they are already exported. Interestingly, libc doesn't seem to have a gamma_r or gammaf_r in the documentation, although an lgamma_r and an lgammaf_r; I am assuming a documentation bug. Intersection of (newlib _r listing from CGF) and (the union of the ope

RE: reentrant functions

2004-04-09 Thread Richard Campbell
Intersection of (newlib _r listing from CGF) and (the union of the opengroup and libc _r functions) (remove leading _): asctime_r ctime_r gmtime_r hcreate_r hdestroy_r hsearch_r jrand48_r lcong48_r lrand48_r localtime_r mrand48_r nrand48_r rand_r seed48_r srand48_r strerror_r strtok_r tmpnam_r A

Re: reentrant functions

2004-04-09 Thread Christopher Faylor
On Fri, Apr 09, 2004 at 10:45:38AM -0400, Christopher Faylor wrote: >newlib does produce a 'rand_r' function, so Buzz's list is incomplete. FWIW, the list below is what I came up with by massaging the output of 'nm' when run on the .a files that newlib produces. It may also be out of date since I

Re: reentrant functions

2004-04-09 Thread Christopher Faylor
On Fri, Apr 09, 2004 at 10:12:56AM -0400, Richard Campbell wrote: >>For a reference of what is acceptable, you can use The Single Unix >>Specification v3: >> >>http://www.opengroup.org/onlinepubs/007904975/toc.htm >> > >All System Interfaces from that specification ending in "_r": > >[snip] >rand_r

RE: reentrant functions

2004-04-09 Thread Richard Campbell
>For a reference of what is acceptable, you can use The Single Unix >Specification v3: > >http://www.opengroup.org/onlinepubs/007904975/toc.htm > All System Interfaces from that specification ending in "_r": asctime_r ctime_r getgrgid_r getgrnam_r getlogin_r getpwnam_r getpwuid_r gmtime_r localti

Re: reentrant functions

2004-04-08 Thread Christopher Faylor
On Fri, Apr 09, 2004 at 04:33:26AM +0200, Bas van Gompel wrote: >[You left very little context. I added some.] > >Op Thu, 8 Apr 2004 21:00:34 -0400 >schreef Christopher Faylor >in <[EMAIL PROTECTED]>: >Christopher Faylor: >>::We also do not want to export _r functions which are unique only to >>::

Re: reentrant functions

2004-04-08 Thread Bas van Gompel
[You left very little context. I added some.] Op Thu, 8 Apr 2004 21:00:34 -0400 schreef Christopher Faylor in <[EMAIL PROTECTED]>: Christopher Faylor: > :: We also do not want to export _r functions which are unique only to > :: newlib. For instance, I suspect that _mallopt_r is probably not >

Re: reentrant functions

2004-04-08 Thread Christopher Faylor
On Fri, Apr 09, 2004 at 02:33:05AM +0200, Bas van Gompel wrote: >That's not what was asked... Aren't you glad I clarified? >Corinna said: >[...] >| Cygwin. Any volunteer to collect these non-exported newlib functions >| so that we can add all of them? > > >Ok, here goes again (this time assumi

Re: reentrant functions

2004-04-08 Thread Bas van Gompel
Op Thu, 8 Apr 2004 16:02:23 -0400 schreef Christopher Faylor in <[EMAIL PROTECTED]>: : On Thu, Apr 08, 2004 at 09:30:47PM +0200, Bas van Gompel wrote: [...] : > $ grep -oR '_[^ ]\+_r *( *struct \+_reent' .|sed 's, *(.*,,'|sort|uniq [...] : > _remove_r and _stat64_r only occur in winsup/cygwin/sys

Re: reentrant functions

2004-04-08 Thread Christopher Faylor
On Thu, Apr 08, 2004 at 09:30:47PM +0200, Bas van Gompel wrote: >Op Wed, 7 Apr 2004 21:46:43 +0200 >schreef Corinna Vinschen >in <[EMAIL PROTECTED]> >in local.ml.cygwin: >: On Apr 6 23:43, Oleg Ostrozhansky wrote: >[...] >: > not thread-safe. But when as an example I try using _gets_r(), I'm >:

Re: reentrant functions

2004-04-08 Thread Bas van Gompel
Op Thu, 8 Apr 2004 21:30:47 +0200 (MET DST) schreef ik in <[EMAIL PROTECTED]>: [...] : $ grep -oR '_[^ ]\+_r *( *struct \+_reent' .|sed 's, *(.*,,'|sort|uniq That should be: $ grep -hoR '_[^ ]\+_r *( *struct \+_reent' .|sed 's, *(.*,,'|sort|uniq [...] L8r, Buzz. -- ) | | ---/ ---/ Yes, t

Re: reentrant functions

2004-04-08 Thread Bas van Gompel
Op Wed, 7 Apr 2004 21:46:43 +0200 schreef Corinna Vinschen in <[EMAIL PROTECTED]> in local.ml.cygwin: : On Apr 6 23:43, Oleg Ostrozhansky wrote: [...] : > not thread-safe. But when as an example I try using _gets_r(), I'm : > getting a link error that this function does not exist: [...] : Many

Re: reentrant functions

2004-04-07 Thread Corinna Vinschen
On Apr 6 23:43, Oleg Ostrozhansky wrote: > I have a question about writing a multi-threaded program (using POSIX.1 > threads) in Cygwin. "info libc" has a nice chapter about reentrancy, > which talks about __r reentrant variants for functions that are > not thread-safe. But when as an example I