summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2010-08-15 11:43:46 +0200
committerVolker Lendecke <vl@samba.org>2010-08-16 22:39:25 +0200
commit68e86969fae55584f12191f09ac0442d09872030 (patch)
tree2520f5c7a427b9504cbb7c9f083de9ac098a6213 /source3/smbd
parent0bd39c73be4cc14ac0961441f8ab3e65d0e9346a (diff)
downloadsamba-68e86969fae55584f12191f09ac0442d09872030.tar.gz
samba-68e86969fae55584f12191f09ac0442d09872030.tar.bz2
samba-68e86969fae55584f12191f09ac0442d09872030.zip
s3: Remove smbd_server_fd() from smbd_process
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/process.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/source3/smbd/process.c b/source3/smbd/process.c
index 769838fa01..7430e35e7c 100644
--- a/source3/smbd/process.c
+++ b/source3/smbd/process.c
@@ -2881,14 +2881,14 @@ void smbd_process(struct smbd_server_connection *sconn)
}
/* Ensure child is set to blocking mode */
- set_blocking(smbd_server_fd(),True);
+ set_blocking(sconn->sock,True);
- set_socket_options(smbd_server_fd(),"SO_KEEPALIVE");
- set_socket_options(smbd_server_fd(), lp_socket_options());
+ set_socket_options(sconn->sock, "SO_KEEPALIVE");
+ set_socket_options(sconn->sock, lp_socket_options());
sa = (struct sockaddr *)(void *)&ss;
sa_len = sizeof(ss);
- ret = getpeername(smbd_server_fd(), sa, &sa_len);
+ ret = getpeername(sconn->sock, sa, &sa_len);
if (ret != 0) {
int level = (errno == ENOTCONN)?2:0;
DEBUG(level,("getpeername() failed - %s\n", strerror(errno)));
@@ -2905,7 +2905,7 @@ void smbd_process(struct smbd_server_connection *sconn)
sa = (struct sockaddr *)(void *)&ss;
sa_len = sizeof(ss);
- ret = getsockname(smbd_server_fd(), sa, &sa_len);
+ ret = getsockname(sconn->sock, sa, &sa_len);
if (ret != 0) {
int level = (errno == ENOTCONN)?2:0;
DEBUG(level,("getsockname() failed - %s\n", strerror(errno)));
@@ -2946,7 +2946,7 @@ void smbd_process(struct smbd_server_connection *sconn)
* the hosts allow list.
*/
- if (!check_access(smbd_server_fd(), lp_hostsallow(-1),
+ if (!check_access(sconn->sock, lp_hostsallow(-1),
lp_hostsdeny(-1))) {
/*
* send a negative session response "not listening on calling
@@ -2956,7 +2956,7 @@ void smbd_process(struct smbd_server_connection *sconn)
DEBUG( 1, ("Connection denied from %s to %s\n",
tsocket_address_string(remote_address, talloc_tos()),
tsocket_address_string(local_address, talloc_tos())));
- (void)srv_send_smb(smbd_server_fd(),(char *)buf, false,
+ (void)srv_send_smb(sconn->sock,(char *)buf, false,
0, false, NULL);
exit_server_cleanly("connection denied");
}
@@ -3095,7 +3095,7 @@ void smbd_process(struct smbd_server_connection *sconn)
sconn->smb1.fde = event_add_fd(smbd_event_context(),
sconn,
- smbd_server_fd(),
+ sconn->sock,
EVENT_FD_READ,
smbd_server_connection_handler,
sconn);