Sun May 3 17:10:21 2009 UTC ()
rump_cred_destroy -> rump_cred_put


(pooka)
diff -r1.11 -r1.12 src/lib/libp2k/p2k.c

cvs diff -r1.11 -r1.12 src/lib/libp2k/p2k.c (expand / switch to unified diff)

--- src/lib/libp2k/p2k.c 2009/04/02 09:30:41 1.11
+++ src/lib/libp2k/p2k.c 2009/05/03 17:10:20 1.12
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: p2k.c,v 1.11 2009/04/02 09:30:41 pooka Exp $ */ 1/* $NetBSD: p2k.c,v 1.12 2009/05/03 17:10:20 pooka Exp $ */
2 2
3/* 3/*
4 * Copyright (c) 2007 Antti Kantee. All Rights Reserved. 4 * Copyright (c) 2007 Antti Kantee. All Rights Reserved.
5 * 5 *
6 * Development of this software was supported by Google Summer of Code. 6 * Development of this software was supported by Google Summer of Code.
7 * 7 *
8 * Redistribution and use in source and binary forms, with or without 8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions 9 * modification, are permitted provided that the following conditions
10 * are met: 10 * are met:
11 * 1. Redistributions of source code must retain the above copyright 11 * 1. Redistributions of source code must retain the above copyright
12 * notice, this list of conditions and the following disclaimer. 12 * notice, this list of conditions and the following disclaimer.
13 * 2. Redistributions in binary form must reproduce the above copyright 13 * 2. Redistributions in binary form must reproduce the above copyright
14 * notice, this list of conditions and the following disclaimer in the 14 * notice, this list of conditions and the following disclaimer in the
@@ -74,27 +74,27 @@ cred_create(const struct puffs_cred *pcr @@ -74,27 +74,27 @@ cred_create(const struct puffs_cred *pcr
74 uid = 0; 74 uid = 0;
75 if (puffs_cred_getgid(pcr, &gid) == -1) 75 if (puffs_cred_getgid(pcr, &gid) == -1)
76 gid = 0; 76 gid = 0;
77 puffs_cred_getgroups(pcr, groups, &ngroups); 77 puffs_cred_getgroups(pcr, groups, &ngroups);
78 78
79 /* LINTED: ngroups is ok */ 79 /* LINTED: ngroups is ok */
80 return rump_cred_create(uid, gid, ngroups, groups); 80 return rump_cred_create(uid, gid, ngroups, groups);
81} 81}
82 82
83static __inline void 83static __inline void
84cred_destroy(kauth_cred_t cred) 84cred_destroy(kauth_cred_t cred)
85{ 85{
86 86
87 rump_cred_destroy(cred); 87 rump_cred_put(cred);
88} 88}
89 89
90static struct componentname * 90static struct componentname *
91makecn(const struct puffs_cn *pcn) 91makecn(const struct puffs_cn *pcn)
92{ 92{
93 kauth_cred_t cred; 93 kauth_cred_t cred;
94 94
95 cred = cred_create(pcn->pcn_cred); 95 cred = cred_create(pcn->pcn_cred);
96 /* LINTED: prehistoric types in first two args */ 96 /* LINTED: prehistoric types in first two args */
97 return rump_makecn(pcn->pcn_nameiop, pcn->pcn_flags, pcn->pcn_name, 97 return rump_makecn(pcn->pcn_nameiop, pcn->pcn_flags, pcn->pcn_name,
98 pcn->pcn_namelen, cred, curlwp); 98 pcn->pcn_namelen, cred, curlwp);
99} 99}
100 100