glibc z Ac: getaddrinfo+AMD64 = Segmentation Fault

Jacek Konieczny jajcus at bnet.pl
Mon Feb 2 11:09:49 CET 2004


On Mon, Feb 02, 2004 at 11:02:31AM +0100, Jakub Bogusz wrote:
> Możesz napisać ten testcase w C?

Jasne. Ale w pythonie było prościej i przyjemniej.

#include <sys/types.h>
#include <sys/socket.h>
#include <netdb.h>
#include <string.h>

int main(int argc,char *argv[]){
struct addrinfo hints,*res;

        memset(&hints,0,sizeof(hints));
        getaddrinfo("serwus.bnet.pl",NULL,&hints,&res);
}

Próbowałem też "www.onet.pl" i "www.pld-linux.org", ale na nich się nie wywala.
Pewnie muszą być rekordy AAAA dla danego hosta, albo odpowiednia ilość rekordów
A.

Pozdrowienia,
	Jacek



More information about the pld-devel-pl mailing list