diff options
author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2012-03-26 23:44:53 +0200 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2012-03-26 23:44:53 +0200 |
commit | 511eff7bf616a313e6fc2397db718a81e93847cc (patch) | |
tree | bc8c7d40221e4f0d728e2c5b3eb0a9802b99d95f /libshouldbeinlibc/ugids.h | |
parent | d4b231dd9f874076c62f35590a9f6b93ca6481d7 (diff) | |
parent | 69056411a354300a17d1e92027435c988508655d (diff) |
Merge branch 'master' of git.savannah.gnu.org:/srv/git/hurd/hurd
Diffstat (limited to 'libshouldbeinlibc/ugids.h')
-rw-r--r-- | libshouldbeinlibc/ugids.h | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/libshouldbeinlibc/ugids.h b/libshouldbeinlibc/ugids.h index 8440b608..10e7a242 100644 --- a/libshouldbeinlibc/ugids.h +++ b/libshouldbeinlibc/ugids.h @@ -23,9 +23,12 @@ #include <stdlib.h> /* For inline function stuff. */ #include <idvec.h> +#include <features.h> -#ifndef UGIDS_EI -#define UGIDS_EI extern inline +#ifdef UGIDS_DEFINE_EI +#define UGIDS_EI +#else +#define UGIDS_EI __extern_inline #endif /* A structure holding a set of the common various types of ids. */ @@ -47,6 +50,16 @@ struct ugids /* Return a new ugids structure, or 0 if an allocation error occurs. */ struct ugids *make_ugids (); +extern void ugids_fini (struct ugids *ugids); + +extern void ugids_free (struct ugids *ugids); + +extern int ugids_is_empty (const struct ugids *ugids); + +extern int ugids_equal (const struct ugids *ugids1, const struct ugids *ugids2); + +#if defined(__USE_EXTERN_INLINES) || defined(UGIDS_DEFINE_EI) + /* Free all resources used by UGIDS except UGIDS itself. */ UGIDS_EI void ugids_fini (struct ugids *ugids) @@ -93,6 +106,8 @@ ugids_equal (const struct ugids *ugids1, const struct ugids *ugids2) && idvec_equal (&ugids1->imp_avail_gids, &ugids2->imp_avail_gids); } +#endif /* Use extern inlines. */ + /* Add all ids in NEW to UGIDS. */ error_t ugids_merge (struct ugids *ugids, const struct ugids *new); |