From c485df9530fda65fb1a2142f53c60638d2ca1923 Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Fri, 12 Aug 2011 14:50:09 +0200 Subject: s3:libsmb: abstract the incoming dispatch function via a function pointer This will allow handling of SMB2 in future. metze --- source3/include/client.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'source3/include') diff --git a/source3/include/client.h b/source3/include/client.h index f44e52f8f6..79ce709069 100644 --- a/source3/include/client.h +++ b/source3/include/client.h @@ -128,6 +128,17 @@ struct cli_state { struct tevent_req *read_smb_req; struct tevent_queue *outgoing; struct tevent_req **pending; + /* + * The incoming dispatch function should return: + * - NT_STATUS_RETRY, if more incoming PDUs are expected. + * - NT_STATUS_OK, if no more processing is desired, e.g. + * the dispatch function called + * tevent_req_done(). + * - All other return values disconnect the connection. + */ + NTSTATUS (*dispatch_incoming)(struct cli_state *cli, + TALLOC_CTX *frame, + uint8_t *inbuf); } conn; struct { -- cgit