summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGerald Carter <jerry@samba.org>2003-10-01 17:02:09 +0000
committerGerald Carter <jerry@samba.org>2003-10-01 17:02:09 +0000
commitb6433f5db77a1d62309946c6f23c18c6c299d0c5 (patch)
tree3ae2f136050a57e0cc751f092689e1b4639f77a1
parent294f376aa908a9c56b73b9bfe48d56012a8f557b (diff)
downloadsamba-b6433f5db77a1d62309946c6f23c18c6c299d0c5.tar.gz
samba-b6433f5db77a1d62309946c6f23c18c6c299d0c5.tar.xz
samba-b6433f5db77a1d62309946c6f23c18c6c299d0c5.zip
merge of parameter changes from 3.0 and fix for bug 550
-rw-r--r--source/lib/system.c8
-rw-r--r--source/lib/system_smbd.c2
-rw-r--r--source/param/loadparm.c5
3 files changed, 7 insertions, 8 deletions
diff --git a/source/lib/system.c b/source/lib/system.c
index b020a203730..2e95efec79b 100644
--- a/source/lib/system.c
+++ b/source/lib/system.c
@@ -693,7 +693,6 @@ int sys_getgroups(int setlen, gid_t *gidset)
#endif /* HAVE_BROKEN_GETGROUPS */
}
-#ifdef HAVE_SETGROUPS
/**************************************************************************
Wrapper for setgroups. Deals with broken (int) case. Automatically used
@@ -702,6 +701,11 @@ int sys_getgroups(int setlen, gid_t *gidset)
int sys_setgroups(int setlen, gid_t *gidset)
{
+#if !defined(HAVE_SETGROUPS)
+ errno = ENOSYS;
+ return -1;
+#endif /* HAVE_SETGROUPS */
+
#if !defined(HAVE_BROKEN_GETGROUPS)
return setgroups(setlen, gidset);
#else
@@ -742,8 +746,6 @@ int sys_setgroups(int setlen, gid_t *gidset)
#endif /* HAVE_BROKEN_GETGROUPS */
}
-#endif /* HAVE_SETGROUPS */
-
/**************************************************************************
Wrappers for setpwent(), getpwent() and endpwent()
****************************************************************************/
diff --git a/source/lib/system_smbd.c b/source/lib/system_smbd.c
index bcbc8c61e64..73c910e631d 100644
--- a/source/lib/system_smbd.c
+++ b/source/lib/system_smbd.c
@@ -92,7 +92,7 @@ static int getgrouplist_internals(const char *user, gid_t gid, gid_t *groups, in
restore_re_gid();
- if (setgroups(ngrp_saved, gids_saved) != 0) {
+ if (sys_setgroups(ngrp_saved, gids_saved) != 0) {
/* yikes! */
DEBUG(0,("ERROR: getgrouplist: failed to reset group list!\n"));
smb_panic("getgrouplist: failed to reset group list!\n");
diff --git a/source/param/loadparm.c b/source/param/loadparm.c
index 0efa2796c36..45626192dbe 100644
--- a/source/param/loadparm.c
+++ b/source/param/loadparm.c
@@ -185,7 +185,6 @@ typedef struct
int mangle_prefix;
int max_log_size;
char *szLogLevel;
- int mangled_stack;
int max_xmit;
int max_mux;
int max_open_files;
@@ -972,7 +971,6 @@ static struct parm_struct parm_table[] = {
{"mangling method", P_STRING, P_GLOBAL, &Globals.szManglingMethod, NULL, NULL, FLAG_ADVANCED},
{"mangle prefix", P_INTEGER, P_GLOBAL, &Globals.mangle_prefix, NULL, NULL, FLAG_ADVANCED},
- {"mangled stack", P_INTEGER, P_GLOBAL, &Globals.mangled_stack, NULL, NULL, FLAG_ADVANCED},
{"default case", P_ENUM, P_LOCAL, &sDefault.iDefaultCase, NULL, enum_case, FLAG_ADVANCED | FLAG_SHARE},
{"case sensitive", P_BOOL, P_LOCAL, &sDefault.bCaseSensitive, NULL, NULL, FLAG_ADVANCED | FLAG_SHARE | FLAG_GLOBAL},
{"casesignames", P_BOOL, P_LOCAL, &sDefault.bCaseSensitive, NULL, NULL, FLAG_HIDE},
@@ -992,7 +990,7 @@ static struct parm_struct parm_table[] = {
{"map hidden", P_BOOL, P_LOCAL, &sDefault.bMap_hidden, NULL, NULL, FLAG_ADVANCED | FLAG_SHARE | FLAG_GLOBAL},
{"map archive", P_BOOL, P_LOCAL, &sDefault.bMap_archive, NULL, NULL, FLAG_ADVANCED | FLAG_SHARE | FLAG_GLOBAL},
{"mangled names", P_BOOL, P_LOCAL, &sDefault.bMangledNames, NULL, NULL, FLAG_ADVANCED | FLAG_SHARE | FLAG_GLOBAL},
- {"mangled map", P_STRING, P_LOCAL, &sDefault.szMangledMap, NULL, NULL, FLAG_ADVANCED | FLAG_SHARE | FLAG_GLOBAL},
+ {"mangled map", P_STRING, P_LOCAL, &sDefault.szMangledMap, NULL, NULL, FLAG_ADVANCED | FLAG_SHARE | FLAG_GLOBAL | FLAG_DEPRECATED },
{"stat cache", P_BOOL, P_GLOBAL, &Globals.bStatCache, NULL, NULL, FLAG_ADVANCED},
{"Domain Options", P_SEP, P_SEPARATOR},
@@ -1361,7 +1359,6 @@ static void init_globals(void)
Globals.AlgorithmicRidBase = BASE_RID;
Globals.bLoadPrinters = True;
- Globals.mangled_stack = 50;
/* Was 65535 (0xFFFF). 0x4101 matches W2K and causes major speed improvements... */
/* Discovered by 2 days of pain by Don McCall @ HP :-). */
Globals.max_xmit = 0x4104;