summaryrefslogtreecommitdiffstats
path: root/source/include
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>1999-02-03 03:18:38 +0000
committerJeremy Allison <jra@samba.org>1999-02-03 03:18:38 +0000
commit87dc4ff92fac7f4f74339180735e2a1132c63fb6 (patch)
treed7ed1981573aa80c15d5d35d4fa4a9df94423d67 /source/include
parent58ed592a48a04d777014817ff6fe8255a684d6d8 (diff)
downloadsamba-87dc4ff92fac7f4f74339180735e2a1132c63fb6.tar.gz
samba-87dc4ff92fac7f4f74339180735e2a1132c63fb6.tar.xz
samba-87dc4ff92fac7f4f74339180735e2a1132c63fb6.zip
Fixed bug where cli->timeout was in milliseconds, but open_sockets_out
was in seconds. This meant that PDC -> BDC failover took so long it essentiually didn't happen. include/client.h: Added explicit comment that cli->timeout should be milliseconds. include/local.h: Changed LONG_CONNECT_TIMEOUT & SHORT_CONNECT_TIMEOUT to be milliseconds. lib/smbrun.c: Tidied up fork failure catching. lib/util_sock.c: Ensured timeout treated as milliseconds. libsmb/clientgen.c: Added comment. rpc_server/srv_pipe_hnd.c: Luke's changes. smbd/chgpasswd.c: Paranoia code for EINTR around sys_waitpid. Jeremy.
Diffstat (limited to 'source/include')
-rw-r--r--source/include/client.h2
-rw-r--r--source/include/local.h6
2 files changed, 4 insertions, 4 deletions
diff --git a/source/include/client.h b/source/include/client.h
index f5226e32e8e..417db1f2575 100644
--- a/source/include/client.h
+++ b/source/include/client.h
@@ -111,7 +111,7 @@ struct cli_state {
uint32 servertime;
int readbraw_supported;
int writebraw_supported;
- int timeout;
+ int timeout; /* in milliseconds. */
int max_xmit;
int max_mux;
char *outbuf;
diff --git a/source/include/local.h b/source/include/local.h
index f8c9770a158..92288a20b80 100644
--- a/source/include/local.h
+++ b/source/include/local.h
@@ -152,9 +152,9 @@
/* shall we support browse requests via a FIFO to nmbd? */
#define ENABLE_FIFO 1
-/* how long to wait for a socket connect to happen */
-#define LONG_CONNECT_TIMEOUT 30
-#define SHORT_CONNECT_TIMEOUT 5
+/* how long (in miliseconds) to wait for a socket connect to happen */
+#define LONG_CONNECT_TIMEOUT 30000
+#define SHORT_CONNECT_TIMEOUT 5000
/* default socket options. Dave Miller thinks we should default to TCP_NODELAY
given the socket IO pattern that Samba uses*/