summaryrefslogtreecommitdiff
path: root/source3/include
diff options
context:
space:
mode:
Diffstat (limited to 'source3/include')
-rw-r--r--source3/include/config.h.in1
-rw-r--r--source3/include/includes.h6
-rw-r--r--source3/include/proto.h5
-rw-r--r--source3/include/smb.h15
4 files changed, 15 insertions, 12 deletions
diff --git a/source3/include/config.h.in b/source3/include/config.h.in
index 3bc3e95e4f..dbbd5431a2 100644
--- a/source3/include/config.h.in
+++ b/source3/include/config.h.in
@@ -104,6 +104,7 @@
#undef WITH_NISPLUS
#undef WITH_AUTOMOUNT
#undef HAVE_PAM_AUTHENTICATE
+#undef HAVE_BROKEN_GETGROUPS
/* The number of bytes in a int. */
#undef SIZEOF_INT
diff --git a/source3/include/includes.h b/source3/include/includes.h
index b63787fd5e..2a420f76ed 100644
--- a/source3/include/includes.h
+++ b/source3/include/includes.h
@@ -287,6 +287,12 @@ extern char *sys_errlist[];
extern int errno;
#endif
+#ifdef HAVE_BROKEN_GETGROUPS
+#define GID_T int
+#else
+#define GID_T gid_t
+#endif
+
/* Lists, trees, caching, datbase... */
#include "ubi_sLinkList.h"
diff --git a/source3/include/proto.h b/source3/include/proto.h
index 523d7c9615..c8c0cc8145 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -1661,8 +1661,7 @@ BOOL last_challenge(unsigned char *challenge);
user_struct *get_valid_user_struct(uint16 vuid);
void invalidate_vuid(uint16 vuid);
char *validated_username(uint16 vuid);
-int setup_groups(char *user, int uid, int gid, int *p_ngroups,
- int **p_igroups, gid_t **p_groups);
+int setup_groups(char *user, int uid, int gid, int *p_ngroups, GID_T **p_groups);
uint16 register_vuid(int uid,int gid, char *unix_name, char *requested_name, BOOL guest);
void add_session_user(char *user);
BOOL update_smbpassword_file( char *user, fstring password);
@@ -1984,7 +1983,7 @@ void *mem_dup( void *from, int size );
void array_promote(char *array,int elsize,int element);
void set_socket_options(int fd, char *options);
void close_sockets(void );
-BOOL in_group(gid_t group, int current_gid, int ngroups, int *groups);
+BOOL in_group(gid_t group, int current_gid, int ngroups, GID_T *groups);
char *StrCpy(char *dest,char *src);
char *StrnCpy(char *dest,char *src,int n);
void putip(void *dest,void *src);
diff --git a/source3/include/smb.h b/source3/include/smb.h
index 1c37aab7e2..8d846d4531 100644
--- a/source3/include/smb.h
+++ b/source3/include/smb.h
@@ -386,11 +386,10 @@ struct cli_state {
struct current_user
{
- int cnum, vuid;
- int uid, gid;
- int ngroups;
- gid_t *groups;
- int *igroups;
+ int cnum, vuid;
+ int uid, gid;
+ int ngroups;
+ GID_T *groups;
};
typedef struct
@@ -500,8 +499,7 @@ typedef struct
/* This groups info is valid for the user that *opened* the connection */
int ngroups;
- gid_t *groups;
- int *igroups; /* an integer version - some OSes are broken :-( */
+ GID_T *groups;
time_t lastused;
BOOL used;
@@ -537,8 +535,7 @@ typedef struct
/* following groups stuff added by ih */
/* This groups info is needed for when we become_user() for this uid */
int n_groups;
- gid_t *groups;
- int *igroups; /* an integer version - some OSes are broken :-( */
+ GID_T *groups;
int n_sids;
int *sids;