* autoload.cc (wsock_init): Properly define WSAStartup function pointer to
avoid stack damage.
This commit is contained in:
parent
103e45ba4d
commit
63398011f9
@ -1,3 +1,8 @@
|
|||||||
|
2011-02-05 Christopher Faylor <me+cygwin@cgf.cx>
|
||||||
|
|
||||||
|
* autoload.cc (wsock_init): Properly define WSAStartup function pointer
|
||||||
|
to avoid stack damage.
|
||||||
|
|
||||||
2011-02-02 Corinna Vinschen <corinna@vinschen.de>
|
2011-02-02 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
* libc/bsdlib.cc: Include err.h.
|
* libc/bsdlib.cc: Include err.h.
|
||||||
|
@ -294,10 +294,10 @@ wsock_init ()
|
|||||||
|
|
||||||
if (!wsock_started)
|
if (!wsock_started)
|
||||||
{
|
{
|
||||||
int (*wsastartup) (int, WSADATA *);
|
int __stdcall (*wsastartup) (int, WSADATA *);
|
||||||
|
|
||||||
/* Don't use autoload to load WSAStartup to eliminate recursion. */
|
/* Don't use autoload to load WSAStartup to eliminate recursion. */
|
||||||
wsastartup = (int (*)(int, WSADATA *))
|
wsastartup = (int __stdcall (*)(int, WSADATA *))
|
||||||
GetProcAddress ((HMODULE) (dll->handle), "WSAStartup");
|
GetProcAddress ((HMODULE) (dll->handle), "WSAStartup");
|
||||||
if (wsastartup)
|
if (wsastartup)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user