Diff for /dietlibc/t.c between versions 1.124 and 1.125

version 1.124, 2001/07/10 21:10:16 version 1.125, 2001/07/11 00:12:39
Line 76  void closelog(void) { Line 76  void closelog(void) {
 #endif  #endif
   
 int main(int argc,char *argv[]) {  int main(int argc,char *argv[]) {
   #if 0
     char buf[1024];
     struct hostent* r;
     while (r=gethostent_r(buf,1024)) {
       if (r && r->h_name) {
         printf("name %s\n", r->h_name);
       }
       if (r && (r->h_addr_list)[0]) {
         struct in_addr address;
         address = *((struct in_addr *) (r->h_addr_list)[0]);
         printf("addr %s\n", inet_ntoa(address));
       }
     }
   #endif
   #if 0
   char *tmp;    char *tmp;
   printf("%lu\n",strtol("0xf0000000",&tmp,0));    printf("%lu\n",strtol("0xf0000000",&tmp,0));
   #endif
 #if 0  #if 0
   struct mntent* me;    struct mntent* me;
   FILE* f=fopen("/tmp/mounts","r");    FILE* f=fopen("/tmp/mounts","r");
Line 392  int main(int argc,char *argv[]) { Line 408  int main(int argc,char *argv[]) {
   strftime(buf,512,"%A %B %Y\n",duh);    strftime(buf,512,"%A %B %Y\n",duh);
   puts(buf);    puts(buf);
 #endif  #endif
 #if 0  #if 1
   struct in_addr bar;    struct in_addr bar;
   struct hostent *foo;    struct hostent *foo;
 /*  inet_aton("160.45.10.8",&bar); */    inet_aton("160.45.10.8",&bar);
   foo=gethostbyname("zeit.fu-berlin.de");  /*  foo=gethostbyname("zeit.fu-berlin.de"); */
 /*  foo=gethostbyaddr(&bar,4,AF_INET); */    foo=gethostbyaddr(&bar,4,AF_INET);
   if (foo)    if (foo)
     printf("%s -> %s\n",foo->h_name,inet_ntoa(*(struct in_addr*)foo->h_addr));      printf("%s -> %s\n",foo->h_name,inet_ntoa(*(struct in_addr*)foo->h_addr));
 /*  printf("%g %g\n",1e-10,1e10); */  /*  printf("%g %g\n",1e-10,1e10); */

Removed from v.1.124  
changed lines
  Added in v.1.125


LinuxTV legacy CVS <linuxtv.org/cvs>