summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSamba Release Account <samba-bugs@samba.org>1997-06-16 20:49:15 +0000
committerSamba Release Account <samba-bugs@samba.org>1997-06-16 20:49:15 +0000
commit54dcca1240ec0a7f107f8a77e0893855015f9d29 (patch)
treea3e172742eef15280b04972b8294def567e30e0f
parentd9a4ff3c908f5564bd30e78485b391dfdb7c9082 (diff)
downloadsamba-54dcca1240ec0a7f107f8a77e0893855015f9d29.tar.gz
samba-54dcca1240ec0a7f107f8a77e0893855015f9d29.tar.xz
samba-54dcca1240ec0a7f107f8a77e0893855015f9d29.zip
charset.c: Dropped debug message to level 6.
loadparm.c: Added "time server" parameter. nameserv.h: Added "time server" parameter. proto.h: Added lp_time_server(). server.c: Removed incorrect | 0700 - this was a whistle specific change. Jeremy (jallison@whistle.com).
-rw-r--r--source/include/nameserv.h3
-rw-r--r--source/include/proto.h1
-rw-r--r--source/lib/charset.c4
-rw-r--r--source/param/loadparm.c4
-rw-r--r--source/smbd/server.c4
5 files changed, 12 insertions, 4 deletions
diff --git a/source/include/nameserv.h b/source/include/nameserv.h
index 1aa1075543f..ae59f952524 100644
--- a/source/include/nameserv.h
+++ b/source/include/nameserv.h
@@ -410,7 +410,8 @@ struct packet_struct
#define REMOTE_ANNOUNCE_INTERVAL 180
#define DFLT_SERVER_TYPE (SV_TYPE_WORKSTATION | SV_TYPE_SERVER | \
- SV_TYPE_TIME_SOURCE | SV_TYPE_SERVER_UNIX | \
+ (lp_time_server() ? SV_TYPE_TIME_SOURCE : 0) | \
+ SV_TYPE_SERVER_UNIX | \
SV_TYPE_PRINTQ_SERVER | SV_TYPE_SERVER_NT | \
SV_TYPE_NT )
diff --git a/source/include/proto.h b/source/include/proto.h
index fd4e2dd23c8..92feccf384f 100644
--- a/source/include/proto.h
+++ b/source/include/proto.h
@@ -167,6 +167,7 @@ BOOL lp_syslog_only(void);
BOOL lp_browse_list(void);
BOOL lp_unix_realname(void);
BOOL lp_nis_home_map(void);
+BOOL lp_time_server(void);
int lp_os_level(void);
int lp_max_ttl(void);
int lp_max_log_size(void);
diff --git a/source/lib/charset.c b/source/lib/charset.c
index a83d1133fef..f066b9a4728 100644
--- a/source/lib/charset.c
+++ b/source/lib/charset.c
@@ -226,7 +226,7 @@ void charset_initialise(int client_codepage)
}
if(client_codepage != -1)
- DEBUG(1,("charset_initialise: client code page = %d\n", client_codepage));
+ DEBUG(6,("charset_initialise: client code page = %d\n", client_codepage));
/*
* Known client codepages - these can be added to.
@@ -245,7 +245,7 @@ void charset_initialise(int client_codepage)
break;
default:
/* Default charset - currently 850 */
- DEBUG(1,("charset_initialise: Using default client codepage %d\n", 850));
+ DEBUG(6,("charset_initialise: Using default client codepage %d\n", 850));
cp = cp_850;
break;
diff --git a/source/param/loadparm.c b/source/param/loadparm.c
index b1e2834ca86..8f0108cc12d 100644
--- a/source/param/loadparm.c
+++ b/source/param/loadparm.c
@@ -174,6 +174,7 @@ typedef struct
BOOL bBrowseList;
BOOL bUnixRealname;
BOOL bNISHomeMap;
+ BOOL bTimeServer;
} global;
static global Globals;
@@ -450,6 +451,7 @@ struct parm_struct
{"browse list", P_BOOL, P_GLOBAL, &Globals.bBrowseList, NULL},
{"unix realname", P_BOOL, P_GLOBAL, &Globals.bUnixRealname, NULL},
{"NIS homedir", P_BOOL, P_GLOBAL, &Globals.bNISHomeMap, NULL},
+ {"time server", P_BOOL, P_GLOBAL, &Globals.bTimeServer, NULL},
{"-valid", P_BOOL, P_LOCAL, &sDefault.valid, NULL},
{"comment", P_STRING, P_LOCAL, &sDefault.comment, NULL},
{"copy", P_STRING, P_LOCAL, &sDefault.szCopy, handle_copy},
@@ -621,6 +623,7 @@ static void init_globals(void)
coding_system = interpret_coding_system (KANJI, SJIS_CODE);
#endif /* KANJI */
Globals.client_code_page = DEFAULT_CLIENT_CODE_PAGE;
+ Globals.bTimeServer = False;
/* these parameters are set to defaults that are more appropriate
for the increasing samba install base:
@@ -813,6 +816,7 @@ FN_GLOBAL_BOOL(lp_syslog_only,&Globals.bSyslogOnly)
FN_GLOBAL_BOOL(lp_browse_list,&Globals.bBrowseList)
FN_GLOBAL_BOOL(lp_unix_realname,&Globals.bUnixRealname)
FN_GLOBAL_BOOL(lp_nis_home_map,&Globals.bNISHomeMap)
+FN_GLOBAL_BOOL(lp_time_server,&Globals.bTimeServer)
FN_GLOBAL_INTEGER(lp_os_level,&Globals.os_level)
FN_GLOBAL_INTEGER(lp_max_ttl,&Globals.max_ttl)
diff --git a/source/smbd/server.c b/source/smbd/server.c
index a44745496b2..c808eac06ac 100644
--- a/source/smbd/server.c
+++ b/source/smbd/server.c
@@ -141,8 +141,10 @@ mode_t unix_mode(int cnum,int dosmode)
result |= (S_IWUSR | S_IWGRP | S_IWOTH);
if (IS_DOS_DIR(dosmode)) {
+ /* We never make directories read only for the owner as under DOS a user
+ can always create a file in a read-only directory. */
result |= (S_IFDIR | S_IXUSR | S_IXGRP | S_IXOTH | S_IWUSR);
- result &= (lp_dir_mode(SNUM(cnum)) | 0700);
+ result &= lp_dir_mode(SNUM(cnum));
} else {
if (MAP_ARCHIVE(cnum) && IS_DOS_ARCHIVE(dosmode))
result |= S_IXUSR;