Patch suggested by Ren� M�ller Fonseca <fonseca@mip.sdu.dk>

* include/sys/socket.h: Change prototype to have 2nd parameter `const'.
        * net.cc (cygwin_bind): Change 2nd parameter to `const'.
This commit is contained in:
Corinna Vinschen 2001-01-09 16:00:58 +00:00
parent 077ec4cb37
commit 55ae1dff87
3 changed files with 10 additions and 4 deletions

View File

@ -1,3 +1,9 @@
Tue Jan 9 16:55:00 2001 Corinna Vinschen <corinna@vinschen.de>
Patch suggested by René Møller Fonseca <fonseca@mip.sdu.dk>
* include/sys/socket.h: Change prototype to have 2nd parameter `const'.
* net.cc (cygwin_bind): Change 2nd parameter to `const'.
Sun Jan 7 22:59:37 2001 Christopher Faylor <cgf@cygnus.com> Sun Jan 7 22:59:37 2001 Christopher Faylor <cgf@cygnus.com>
* pinfo.cc (codepage_init): Move function. * pinfo.cc (codepage_init): Move function.
@ -8,7 +14,7 @@ Sun Jan 7 22:59:37 2001 Christopher Faylor <cgf@cygnus.com>
* sigproc.cc (wait_sig): Ditto. * sigproc.cc (wait_sig): Ditto.
* winsup.h: Eliminate global declaration of codepage_init. * winsup.h: Eliminate global declaration of codepage_init.
Thu Jan 5 9:33:00 2001 Corinna Vinschen <corina@vinschen.de> Thu Jan 5 9:33:00 2001 Corinna Vinschen <corinna@vinschen.de>
* resource.cc (getrlimit): Set errno on EFAULT instead of returning * resource.cc (getrlimit): Set errno on EFAULT instead of returning
it. it.

View File

@ -17,7 +17,7 @@ extern "C"
#ifndef __INSIDE_CYGWIN_NET__ #ifndef __INSIDE_CYGWIN_NET__
int accept (int, struct sockaddr *__peer, int *); int accept (int, struct sockaddr *__peer, int *);
int bind (int, struct sockaddr *__my_addr, int __addrlen); int bind (int, const struct sockaddr *__my_addr, int __addrlen);
int connect (int, const struct sockaddr *, int); int connect (int, const struct sockaddr *, int);
int getpeername (int, struct sockaddr *__peer, int *); int getpeername (int, struct sockaddr *__peer, int *);
int getsockname (int, struct sockaddr *__addr, int *); int getsockname (int, struct sockaddr *__addr, int *);

View File

@ -1,6 +1,6 @@
/* net.cc: network-related routines. /* net.cc: network-related routines.
Copyright 1996, 1997, 1998, 1999, 2000 Cygnus Solutions. Copyright 1996, 1997, 1998, 1999, 2000, 2001 Cygnus Solutions.
This file is part of Cygwin. This file is part of Cygwin.
@ -760,7 +760,7 @@ done:
/* exported as bind: standards? */ /* exported as bind: standards? */
extern "C" int extern "C" int
cygwin_bind (int fd, struct sockaddr *my_addr, int addrlen) cygwin_bind (int fd, const struct sockaddr *my_addr, int addrlen)
{ {
int res = -1; int res = -1;