summaryrefslogtreecommitdiff
path: root/source4/libcli
diff options
context:
space:
mode:
Diffstat (limited to 'source4/libcli')
-rw-r--r--source4/libcli/raw/clitransport.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/source4/libcli/raw/clitransport.c b/source4/libcli/raw/clitransport.c
index 2d29ba371f..85d5337da7 100644
--- a/source4/libcli/raw/clitransport.c
+++ b/source4/libcli/raw/clitransport.c
@@ -21,6 +21,10 @@
#include "includes.h"
+
+static void smbcli_transport_process_recv(struct smbcli_transport *transport);
+static void smbcli_transport_process_send(struct smbcli_transport *transport);
+
/*
an event has happened on the socket
*/
@@ -29,7 +33,12 @@ static void smbcli_transport_event_handler(struct event_context *ev, struct fd_e
{
struct smbcli_transport *transport = fde->private;
- smbcli_transport_process(transport);
+ if (flags & EVENT_FD_READ) {
+ smbcli_transport_process_recv(transport);
+ }
+ if (flags & EVENT_FD_WRITE) {
+ smbcli_transport_process_send(transport);
+ }
}
/*
@@ -265,6 +274,7 @@ static void smbcli_transport_process_send(struct smbcli_transport *transport)
return;
}
smbcli_transport_dead(transport);
+ return;
}
req->out.buffer += ret;
req->out.size -= ret;