cURL / Mailing Lists / curl-library / Single Mail

curl-library

getsockname problem ??

From: Peter Sylvester <Peter.Sylvester_at_edelweb.fr>
Date: Tue, 22 Aug 2006 17:36:04 +0200

AllowServerConnect in ftp.c has the following pieces;

socklen_t size = (socklen_t) sizeof(struct sockaddr_in);
...
getsockname(sock, (struct sockaddr *) &add, &size);
...
s=accept(sock, (struct sockaddr *) &add, &size);

At least on my linux with ipv6 enabled the initial value is
16 and getsockname updates this to 28, this the following
accept call still works but corrupts the stack.

tests 253 and 255 fail because of this. Setting back the size value
fixes the problem.

-- 
To verify the signature, see http://edelpki.edelweb.fr/ 
Cela vous permet de charger le certificat de l'autorite'; 
die Liste mit zuru"ckgerufenen Zertifikaten finden Sie da auch. 

Received on 2006-08-22