privilegeset_ref(): return the privilegeset

This commit is contained in:
William Pitcock 2008-08-17 08:22:56 -05:00
parent 5a6d4202d1
commit 665e79e999
2 changed files with 4 additions and 2 deletions

View File

@ -42,7 +42,7 @@ int privilegeset_in_set(struct PrivilegeSet *set, const char *priv);
struct PrivilegeSet *privilegeset_set_new(const char *name, const char *privs, PrivilegeFlags flags);
struct PrivilegeSet *privilegeset_extend(struct PrivilegeSet *parent, const char *name, const char *privs, PrivilegeFlags flags);
struct PrivilegeSet *privilegeset_get(const char *name);
void privilegeset_ref(struct PrivilegeSet *set);
struct PrivilegeSet *privilegeset_ref(struct PrivilegeSet *set);
void privilegeset_unref(struct PrivilegeSet *set);
#endif

View File

@ -95,12 +95,14 @@ privilegeset_get(const char *name)
return NULL;
}
void
struct PrivilegeSet *
privilegeset_ref(struct PrivilegeSet *set)
{
s_assert(set != NULL);
set->refs++;
return set;
}
void