This is the mail archive of the
cygwin-patches@cygwin.com
mailing list for the Cygwin project.
Re: src/winsup/cygwin ChangeLog autoload.cc autolo ...
- To: cygwin-patches at cygwin dot com
- Subject: Re: src/winsup/cygwin ChangeLog autoload.cc autolo ...
- From: Corinna Vinschen <cygwin-patches at cygwin dot com>
- Date: Thu, 3 May 2001 13:06:08 +0200
- References: <20010503093508.13491.qmail@sourceware.cygnus.com> <132246850181.20010503140017@logos-m.ru>
On Thu, May 03, 2001 at 02:00:17PM +0400, egor duda wrote:
> Hi!
>
> Thursday, 03 May, 2001 corinna@sourceware.cygnus.com wrote:
>
> cscc> * net.cc (wsock_init): Add guard variable handling. Take care
> cscc> to call WSAStartup only once. Load WSAStartup without using
> cscc> autoload wrapper to eliminate recursion. Eliminate FIONBIO
> cscc> and srandom stuff.
>
> actually, srandom stuff was calles purposively in wsock_init. it's
> supposed to make secret cookies for AF_UNIX sockets random. i know
> that calling srandom() isn't the best way to assure this, but it's
> better than nothing. I'll probably replace newlib's random to calls to
> windows crypto-api, but until then, i think, srandom should be called
> during init.
Calling srandom isn't correct since the random number generator
has to be initialized with a seed of 1 by default. Calling
srandom inside of Cygwin destroys that behaviour, unfortunately.
Corinna
--
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Developer mailto:cygwin@cygwin.com
Red Hat, Inc.