aboutsummaryrefslogtreecommitdiff
path: root/src/libauth/auth_respond.c
diff options
context:
space:
mode:
authorrsc <devnull@localhost>2005-02-08 20:58:10 +0000
committerrsc <devnull@localhost>2005-02-08 20:58:10 +0000
commit648bb6f75a801e6d605fcd061f0b14fecc07a8be (patch)
treeae995dfa5c1807dfa8902f5120ef6933911aebb5 /src/libauth/auth_respond.c
parentfa467fbe51e3aba23fce6639afd8939c046c8c2d (diff)
downloadplan9port-648bb6f75a801e6d605fcd061f0b14fecc07a8be.tar.gz
plan9port-648bb6f75a801e6d605fcd061f0b14fecc07a8be.tar.bz2
plan9port-648bb6f75a801e6d605fcd061f0b14fecc07a8be.zip
lucho changes
Diffstat (limited to 'src/libauth/auth_respond.c')
-rw-r--r--src/libauth/auth_respond.c10
1 files changed, 1 insertions, 9 deletions
diff --git a/src/libauth/auth_respond.c b/src/libauth/auth_respond.c
index 910f06b2..d39facfd 100644
--- a/src/libauth/auth_respond.c
+++ b/src/libauth/auth_respond.c
@@ -28,17 +28,11 @@ auth_respond(void *chal, uint nchal, char *user, uint nuser, void *resp, uint nr
{
char *p, *s;
va_list arg;
- int afd;
AuthRpc *rpc;
Attr *a;
- if((afd = open("/mnt/factotum/rpc", ORDWR)) < 0)
+ if((rpc = auth_allocrpc()) == nil)
return -1;
-
- if((rpc = auth_allocrpc(afd)) == nil){
- close(afd);
- return -1;
- }
quotefmtinstall(); /* just in case */
va_start(arg, fmt);
@@ -50,7 +44,6 @@ auth_respond(void *chal, uint nchal, char *user, uint nuser, void *resp, uint nr
|| dorpc(rpc, "write", chal, nchal, getkey) != ARok
|| dorpc(rpc, "read", nil, 0, getkey) != ARok){
free(p);
- close(afd);
auth_freerpc(rpc);
return -1;
}
@@ -67,7 +60,6 @@ auth_respond(void *chal, uint nchal, char *user, uint nuser, void *resp, uint nr
user[0] = '\0';
_freeattr(a);
- close(afd);
auth_freerpc(rpc);
return nresp;
}