summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorchris <>2005-11-28 15:35:21 +0000
committerchris <>2005-11-28 15:35:21 +0000
commitb60fe9ceeb44e451b1b33fc78398a2b457ba26e8 (patch)
tree6499234507d9cdd5215761040117fca815993d9f
parent5069cba411938a05f88a68018082150b02250e62 (diff)
downloadiftop-b60fe9ceeb44e451b1b33fc78398a2b457ba26e8.zip
Oops.
-rw-r--r--resolver.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/resolver.c b/resolver.c
index 3754654..3d8935e 100644
--- a/resolver.c
+++ b/resolver.c
@@ -314,7 +314,7 @@ char *do_resolve(struct in_addr *addr) {
if (!workerinfo) {
int p[2];
- if (socketpair(AF_UNIX, SOCK_DGRAM, PF_UNSPEC, p) == -1)
+ if (socketpair(AF_UNIX, SOCK_STREAM, PF_UNSPEC, p) == -1)
return NULL;
workerinfo = xmalloc(sizeof *workerinfo);
@@ -341,7 +341,7 @@ char *do_resolve(struct in_addr *addr) {
|| read(workerinfo->fd, name, NAMESIZE) != NAMESIZE) {
/* Something went wrong. Just kill the child and get on with it. */
kill(workerinfo->child, SIGKILL);
- wait();
+ wait(NULL);
close(workerinfo->fd);
xfree(workerinfo);
pthread_setspecific(worker_key, NULL);