Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 175555 Details for
Bug 250468
sys-libs/glibc-2.9_p20081201 cannot resolve certain names
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
Sample test C code
getaddrinfo_test.c (text/plain), 592 bytes, created by
Marcin Deranek
on 2008-12-17 00:37:33 UTC
(
hide
)
Description:
Sample test C code
Filename:
MIME Type:
Creator:
Marcin Deranek
Created:
2008-12-17 00:37:33 UTC
Size:
592 bytes
patch
obsolete
>#include <stdio.h> >#include <sys/types.h> >#include <sys/socket.h> >#include <netdb.h> >#include <string.h> > >int main() { > struct addrinfo hints, *aitop; > int i,err; > char *hosts[]= { > "www.gentoo.org", > "www.debian.org", > "www.google.com", > "www.yahoo.com", > "www.ripe.net", > "gnu.org", > "www.gnu.org" > }; > > for (i=0; i<sizeof(hosts)/sizeof(char *); i++) { > memset(&hints, 0, sizeof(hints)); > hints.ai_family = PF_UNSPEC; > hints.ai_socktype = SOCK_STREAM; > err=getaddrinfo(hosts[i], NULL, &hints, &aitop); > printf("%s: %s\n",hosts[i],(err)? gai_strerror(err):"OK"); > } >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 250468
: 175555 |
182205