summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2009-03-19 09:06:38 +0100
committerStefan Metzmacher <metze@samba.org>2009-03-19 13:54:17 +0100
commit0dfdb7b911ed4fe013fc4a22a8c3a28620277a67 (patch)
tree324a1effbf7f6e164b1a69cea0429f8dea9dbaf6
parent2d1fcdc8072d53dfdb0f0a30911cdeac4aa06f35 (diff)
downloadsamba-0dfdb7b911ed4fe013fc4a22a8c3a28620277a67.tar.gz
samba-0dfdb7b911ed4fe013fc4a22a8c3a28620277a67.tar.bz2
samba-0dfdb7b911ed4fe013fc4a22a8c3a28620277a67.zip
s3:lib/util_sock: use sys_recv() instead of sys_read() on sockets
This ways the pcap support in socket wrapper sees the received data. metze
-rw-r--r--source3/lib/util_sock.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/lib/util_sock.c b/source3/lib/util_sock.c
index de5b232aac..a0dbca1a00 100644
--- a/source3/lib/util_sock.c
+++ b/source3/lib/util_sock.c
@@ -519,7 +519,7 @@ NTSTATUS read_socket_with_timeout(int fd, char *buf,
}
while (nread < mincnt) {
- readret = sys_read(fd, buf + nread, maxcnt - nread);
+ readret = sys_recv(fd, buf + nread, maxcnt - nread, 0);
if (readret == 0) {
DEBUG(5,("read_socket_with_timeout: "
@@ -588,7 +588,7 @@ NTSTATUS read_socket_with_timeout(int fd, char *buf,
return NT_STATUS_IO_TIMEOUT;
}
- readret = sys_read(fd, buf+nread, maxcnt-nread);
+ readret = sys_recv(fd, buf+nread, maxcnt-nread, 0);
if (readret == 0) {
/* we got EOF on the file descriptor */