From 3ee87bca47e74aa2719352485b80973ca6e079b7 Mon Sep 17 00:00:00 2001 From: Julian Pullen Date: Tue, 19 Aug 2008 10:06:21 +0100 Subject: 6727286 libidmap should cache ID mappings --- usr/src/lib/libsec/common/acltext.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'usr/src/lib/libsec/common/acltext.c') diff --git a/usr/src/lib/libsec/common/acltext.c b/usr/src/lib/libsec/common/acltext.c index be2a417040..72d491a784 100644 --- a/usr/src/lib/libsec/common/acltext.c +++ b/usr/src/lib/libsec/common/acltext.c @@ -23,7 +23,6 @@ * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" /*LINTLIBRARY*/ #include @@ -140,19 +139,23 @@ prsidname(uid_t who, boolean_t user, char **sidp, int noresolve) */ if (user) - error = idmap_getwinnamebyuid(who, &name, &domain); + error = idmap_getwinnamebyuid(who, IDMAP_REQ_FLG_USE_CACHE, + &name, &domain); else - error = idmap_getwinnamebygid(who, &name, &domain); + error = idmap_getwinnamebygid(who, IDMAP_REQ_FLG_USE_CACHE, + &name, &domain); if (error) { if (idmap_init(&idmap_hdl) == 0 && idmap_get_create(idmap_hdl, &get_hdl) == 0) { if (user) error = idmap_get_sidbyuid(get_hdl, who, - 0, &domain, &rid, &status); + IDMAP_REQ_FLG_USE_CACHE, &domain, &rid, + &status); else error = idmap_get_sidbygid(get_hdl, who, - 0, &domain, &rid, &status); + IDMAP_REQ_FLG_USE_CACHE, &domain, &rid, + &status); if (error == 0) error = idmap_get_mappings(get_hdl); } -- cgit v1.2.3