Subversion Repositories Kolibri OS

Rev

Blame | Last modification | View Log | Download | RSS feed

  1. #ifndef _LINUX_UIDGID_H
  2. #define _LINUX_UIDGID_H
  3.  
  4. /*
  5.  * A set of types for the internal kernel types representing uids and gids.
  6.  *
  7.  * The types defined in this header allow distinguishing which uids and gids in
  8.  * the kernel are values used by userspace and which uid and gid values are
  9.  * the internal kernel values.  With the addition of user namespaces the values
  10.  * can be different.  Using the type system makes it possible for the compiler
  11.  * to detect when we overlook these differences.
  12.  *
  13.  */
  14. #include <linux/types.h>
  15. typedef struct {
  16.         uid_t val;
  17. } kuid_t;
  18.  
  19.  
  20. typedef struct {
  21.         gid_t val;
  22. } kgid_t;
  23.  
  24. #define KUIDT_INIT(value) (kuid_t){ value }
  25. #define KGIDT_INIT(value) (kgid_t){ value }
  26.  
  27. #endif /* _LINUX_UIDGID_H */
  28.