summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIlia Alshanetsky <iliaa@php.net>2003-01-14 17:45:31 +0000
committerIlia Alshanetsky <iliaa@php.net>2003-01-14 17:45:31 +0000
commit62f7e2714130efa8390128804166f3d482ced79b (patch)
tree0953e20f956ad125d43edce56fb6e64d8afda78e
parent7d14dae0bbd354afb78b04f6259597ede7b237d2 (diff)
downloadphp-git-62f7e2714130efa8390128804166f3d482ced79b.tar.gz
Fixed compile warning & removed useless variable.
-rw-r--r--ext/hyperwave/hg_comm.c13
1 files changed, 4 insertions, 9 deletions
diff --git a/ext/hyperwave/hg_comm.c b/ext/hyperwave/hg_comm.c
index fb5517c14f..856b1c1bfa 100644
--- a/ext/hyperwave/hg_comm.c
+++ b/ext/hyperwave/hg_comm.c
@@ -42,6 +42,7 @@
# include <netdb.h>
# include <unistd.h>
# include <sys/param.h>
+# include <arpa/inet.h>
#endif
#include <fcntl.h>
#include <errno.h>
@@ -5034,10 +5035,8 @@ int send_pipedocument(int sockfd, char *host, hw_objectID objectID, int mode, in
switch(hostptr->h_addrtype) {
struct in_addr *ptr1;
- char *ptr;
case AF_INET:
- ptr = hostptr->h_addr_list[0];
- ptr1 = (struct in_addr *) ptr;
+ ptr1 = (struct in_addr *) hostptr->h_addr_list[0];
hostip = inet_ntoa(*ptr1);
break;
default:
@@ -5221,10 +5220,8 @@ int send_pipecgi(int sockfd, char *host, hw_objectID objectID, char *cgi_env_str
switch(hostptr->h_addrtype) {
struct in_addr *ptr1;
- char *ptr;
case AF_INET:
- ptr = hostptr->h_addr_list[0];
- ptr1 = (struct in_addr *) ptr;
+ ptr1 = (struct in_addr *) hostptr->h_addr_list[0];
hostip = inet_ntoa(*ptr1);
break;
default:
@@ -5403,10 +5400,8 @@ int send_putdocument(int sockfd, char *host, hw_objectID parentID, char *objectR
switch(hostptr->h_addrtype) {
struct in_addr *ptr1;
- char *ptr;
case AF_INET:
- ptr = hostptr->h_addr_list[0];
- ptr1 = (struct in_addr *) ptr;
+ ptr1 = (struct in_addr *) hostptr->h_addr_list[0];
hostip = inet_ntoa(*ptr1);
break;
default: