30 lines
612 B
Text
30 lines
612 B
Text
$NetBSD: patch-ac,v 1.2 2007/06/18 19:00:22 minskim Exp $
|
|
|
|
--- Head.c.orig 2002-11-21 23:38:03.000000000 -0800
|
|
+++ Head.c
|
|
@@ -1,7 +1,7 @@
|
|
|
|
#define _XOPEN_SOURCE 500
|
|
|
|
-
|
|
+#include <errno.h>
|
|
#include <stdio.h>
|
|
#include <unistd.h>
|
|
#include <stdlib.h>
|
|
@@ -30,7 +30,6 @@
|
|
#include "Misc.h"
|
|
|
|
|
|
-extern int errno;
|
|
extern int h_errno;
|
|
|
|
|
|
@@ -55,7 +54,7 @@ void http_head_req(struct request *req)
|
|
hstrerror(h_errno));
|
|
exit(1);
|
|
}
|
|
- strncpy(req->ip, inet_ntoa(*(struct in_addr *)he->h_addr), MAXIPSIZ);
|
|
+ strncpy(req->ip, inet_ntoa(*(struct in_addr *)he->h_addr_list[0]), MAXIPSIZ);
|
|
|
|
|
|
time(&t_start);
|