summaryrefslogtreecommitdiff
path: root/usr.bin/rusers
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2001-06-18 22:19:05 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2001-06-18 22:19:05 +0000
commit94cb8e20aa7a5c22b227f8edd5ea62b488d4b0f2 (patch)
tree2ea3681c25fe34b2b21c25a2b1954b511541c859 /usr.bin/rusers
parent1d0aad3e84d8673482d60b10adabe787ac70d28a (diff)
clnt leaks; tommy@ti.com
Diffstat (limited to 'usr.bin/rusers')
-rw-r--r--usr.bin/rusers/rusers.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/usr.bin/rusers/rusers.c b/usr.bin/rusers/rusers.c
index d89d604d870..b342e8579c0 100644
--- a/usr.bin/rusers/rusers.c
+++ b/usr.bin/rusers/rusers.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rusers.c,v 1.11 2001/02/17 16:52:23 pjanzen Exp $ */
+/* $OpenBSD: rusers.c,v 1.12 2001/06/18 22:19:04 deraadt Exp $ */
/*-
* Copyright (c) 1993 John Brezak
@@ -29,7 +29,7 @@
*/
#ifndef lint
-static char rcsid[] = "$OpenBSD: rusers.c,v 1.11 2001/02/17 16:52:23 pjanzen Exp $";
+static char rcsid[] = "$OpenBSD: rusers.c,v 1.12 2001/06/18 22:19:04 deraadt Exp $";
#endif /* not lint */
#include <sys/types.h>
@@ -216,10 +216,12 @@ onehost(char *host)
if (clnt_call(rusers_clnt, RUSERSPROC_NAMES, xdr_void, NULL,
xdr_utmpidlearr, &up, timeout) != RPC_SUCCESS) {
clnt_perror(rusers_clnt, __progname);
+ clnt_destroy(rusers_clnt);
exit(1);
}
addr.sin_addr.s_addr = *(int *)hp->h_addr;
rusers_reply((char *)&up, &addr);
+ clnt_destroy(rusers_clnt);
}
void