summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2012-03-14 14:59:45 +0100
committerStefan Metzmacher <metze@samba.org>2012-03-15 07:35:28 +0100
commit946eca438d0e0beb34e66f031f64acd44afea074 (patch)
treec0fcd8d906a663835402d4aa07c60eb899f72e25 /source4
parent080549f4675484d0de16c5bfae162513f13fcab6 (diff)
downloadsamba-946eca438d0e0beb34e66f031f64acd44afea074.tar.gz
samba-946eca438d0e0beb34e66f031f64acd44afea074.tar.bz2
samba-946eca438d0e0beb34e66f031f64acd44afea074.zip
s4:librpc/rpc: also notify requests which are not shipped about a dead connection
metze
Diffstat (limited to 'source4')
-rw-r--r--source4/librpc/rpc/dcerpc.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/source4/librpc/rpc/dcerpc.c b/source4/librpc/rpc/dcerpc.c
index ed527b8055..3243644721 100644
--- a/source4/librpc/rpc/dcerpc.c
+++ b/source4/librpc/rpc/dcerpc.c
@@ -1015,6 +1015,17 @@ static void dcerpc_connection_dead(struct dcecli_connection *conn, NTSTATUS stat
}
}
+ /* all requests, which are not shipped */
+ while (conn->request_queue) {
+ struct rpc_request *req = conn->request_queue;
+ dcerpc_req_dequeue(req);
+ req->state = RPC_REQUEST_DONE;
+ req->status = status;
+ if (req->async.callback) {
+ req->async.callback(req);
+ }
+ }
+
talloc_set_destructor(conn, NULL);
if (conn->free_skipped) {
talloc_free(conn);