summaryrefslogtreecommitdiffstats
path: root/source/smbd/server.c
diff options
context:
space:
mode:
authorSamba Release Account <samba-bugs@samba.org>1997-06-06 16:14:17 +0000
committerSamba Release Account <samba-bugs@samba.org>1997-06-06 16:14:17 +0000
commit77be0f710cc96441d966ab7b026a0d591b01ffb0 (patch)
treead2f787882576ebcb1fef19a84b59bb500ba1e52 /source/smbd/server.c
parentb40d3bede60c8e040ee30c72d605a4950e1a8c8b (diff)
downloadsamba-77be0f710cc96441d966ab7b026a0d591b01ffb0.tar.gz
samba-77be0f710cc96441d966ab7b026a0d591b01ffb0.tar.xz
samba-77be0f710cc96441d966ab7b026a0d591b01ffb0.zip
loadparm.c: Made explicit max packet now ignored.
namedbwork.c: Don't announce potential browser if local master = False. nameelect.c: Raise debug level of comment to 2. proto.h: Added reset_globals_after_fork(). server.c: Call reset_globals_after_fork() after forking child. util.c: Added reset_globals_after_fork() - should stop problems with % substitutions in children.
Diffstat (limited to 'source/smbd/server.c')
-rw-r--r--source/smbd/server.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/source/smbd/server.c b/source/smbd/server.c
index 51710b7b779..299ae07aa30 100644
--- a/source/smbd/server.c
+++ b/source/smbd/server.c
@@ -2065,6 +2065,7 @@ static BOOL open_sockets(BOOL is_daemon,int port)
#else
if (Client != -1 && fork()==0)
{
+ /* Child code ... */
#ifndef NO_SIGNAL_TEST
signal(SIGPIPE, SIGNAL_CAST sig_pipe);
signal(SIGCLD, SIGNAL_CAST SIG_DFL);
@@ -2079,6 +2080,11 @@ static BOOL open_sockets(BOOL is_daemon,int port)
set_socket_options(Client,"SO_KEEPALIVE");
set_socket_options(Client,user_socket_options);
+ /* Reset global variables in util.c so that
+ client substitutions will be done correctly
+ in the process.
+ */
+ reset_globals_after_fork();
return True;
}
close(Client); /* The parent doesn't need this socket */
@@ -3119,7 +3125,7 @@ BOOL yield_connection(int cnum,char *name,int max_connections)
f = fopen(fname,"r+");
if (!f)
{
- DEBUG(2,("Coudn't open lock file %s (%s)\n",fname,strerror(errno)));
+ DEBUG(2,("Couldn't open lock file %s (%s)\n",fname,strerror(errno)));
return(False);
}