privilegeset_ref(): return the privilegeset

This commit is contained in:
William Pitcock 2008-08-17 08:22:56 -05:00
parent 49b0375d62
commit 598b4cf10c
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