Use kcm_client

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14557 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Luke Howard
2005-02-03 09:14:00 +00:00
parent 6c9040b3cb
commit 29e616b3f6

View File

@@ -46,11 +46,7 @@ struct descr {
struct sockaddr_storage __ss;
struct sockaddr *sa;
socklen_t sock_len;
struct {
uid_t uid;
gid_t gid;
pid_t pid;
} peercred;
kcm_client peercred;
};
static void
@@ -211,20 +207,15 @@ do_request(void *buf, size_t len, struct descr *d)
{
krb5_error_code ret;
krb5_data reply;
kcm_client client;
client.pid = d->peercred.pid;
client.uid = d->peercred.uid;
client.gid = d->peercred.gid;
reply.length = 0;
ret = process_request(buf, len, &reply, &client);
ret = process_request(buf, len, &reply, &d->peercred);
if (reply.length != 0) {
unsigned char len[4];
kcm_log(5, "sending %lu bytes to process %d", (unsigned long)reply.length,
client.pid);
d->peercred.pid);
len[0] = (reply.length >> 24) & 0xff;
len[1] = (reply.length >> 16) & 0xff;