summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
Diffstat (limited to 'source4')
-rw-r--r--source4/libcli/raw/clitransport.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source4/libcli/raw/clitransport.c b/source4/libcli/raw/clitransport.c
index 2aebb92790..fba6c36bbe 100644
--- a/source4/libcli/raw/clitransport.c
+++ b/source4/libcli/raw/clitransport.c
@@ -347,7 +347,7 @@ static NTSTATUS smbcli_transport_finish_recv(void *private, DATA_BLOB blob)
uint8_t *buffer, *hdr, *vwv;
int len;
uint16_t wct=0, mid = 0, op = 0;
- struct smbcli_request *req;
+ struct smbcli_request *req = NULL;
buffer = blob.data;
len = blob.length;
@@ -482,6 +482,9 @@ error:
if (req) {
DLIST_REMOVE(transport->pending_recv, req);
req->state = SMBCLI_REQUEST_ERROR;
+ if (req->async.fn) {
+ req->async.fn(req);
+ }
} else {
talloc_free(buffer);
}