diff options
author | Stefan Metzmacher <metze@samba.org> | 2011-07-12 09:20:02 +0200 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2011-07-12 10:53:52 +0200 |
commit | 8a234cbe1589439497608d35f35768c6841750c9 (patch) | |
tree | 10b7cad96fa9a00a57456c818e870867459214cf /source3/libsmb | |
parent | a6b128912b60f79258a41131f942e19d6292f9a3 (diff) | |
download | samba-8a234cbe1589439497608d35f35768c6841750c9.tar.gz samba-8a234cbe1589439497608d35f35768c6841750c9.tar.bz2 samba-8a234cbe1589439497608d35f35768c6841750c9.zip |
s3:libsmb: remove unused cli_oplock_handler()
metze
Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Tue Jul 12 10:53:52 CEST 2011 on sn-devel-104
Diffstat (limited to 'source3/libsmb')
-rw-r--r-- | source3/libsmb/clientgen.c | 1 | ||||
-rw-r--r-- | source3/libsmb/clioplock.c | 47 | ||||
-rw-r--r-- | source3/libsmb/proto.h | 3 |
3 files changed, 0 insertions, 51 deletions
diff --git a/source3/libsmb/clientgen.c b/source3/libsmb/clientgen.c index bcb1215579..d6c7d64733 100644 --- a/source3/libsmb/clientgen.c +++ b/source3/libsmb/clientgen.c @@ -191,7 +191,6 @@ struct cli_state *cli_initialise_ex(int signing_state) cli->protocol = PROTOCOL_NT1; cli->timeout = 20000; /* Timeout is in milliseconds. */ cli->max_xmit = CLI_BUFFER_SIZE+4; - cli->oplock_handler = cli_oplock_ack; cli->case_sensitive = false; cli->use_spnego = lp_client_use_spnego(); diff --git a/source3/libsmb/clioplock.c b/source3/libsmb/clioplock.c index da55f971a8..f164ed5221 100644 --- a/source3/libsmb/clioplock.c +++ b/source3/libsmb/clioplock.c @@ -83,50 +83,3 @@ NTSTATUS cli_oplock_ack_recv(struct tevent_req *req) return tevent_req_simple_recv_ntstatus(req); } -NTSTATUS cli_oplock_ack(struct cli_state *cli, uint16_t fnum, unsigned char level) -{ - TALLOC_CTX *frame = talloc_stackframe(); - struct event_context *ev; - struct tevent_req *req; - NTSTATUS status = NT_STATUS_OK; - - if (cli_has_async_calls(cli)) { - /* - * Can't use sync call while an async call is in flight - */ - status = NT_STATUS_INVALID_PARAMETER; - goto fail; - } - - ev = event_context_init(frame); - if (ev == NULL) { - status = NT_STATUS_NO_MEMORY; - goto fail; - } - - req = cli_oplock_ack_send(frame, ev, cli, fnum, level); - if (req == NULL) { - status = NT_STATUS_NO_MEMORY; - goto fail; - } - - if (!tevent_req_poll(req, ev)) { - status = map_nt_error_from_unix(errno); - goto fail; - } - - status = cli_oplock_ack_recv(req); - fail: - TALLOC_FREE(frame); - return status; -} - -/**************************************************************************** -set the oplock handler for a connection -****************************************************************************/ - -void cli_oplock_handler(struct cli_state *cli, - NTSTATUS (*handler)(struct cli_state *, uint16_t, unsigned char)) -{ - cli->oplock_handler = handler; -} diff --git a/source3/libsmb/proto.h b/source3/libsmb/proto.h index 66ab6e6b15..0029db13e2 100644 --- a/source3/libsmb/proto.h +++ b/source3/libsmb/proto.h @@ -687,9 +687,6 @@ struct tevent_req *cli_oplock_ack_send(TALLOC_CTX *mem_ctx, struct cli_state *cli, uint16_t fnum, uint8_t level); NTSTATUS cli_oplock_ack_recv(struct tevent_req *req); -NTSTATUS cli_oplock_ack(struct cli_state *cli, uint16_t fnum, unsigned char level); -void cli_oplock_handler(struct cli_state *cli, - NTSTATUS (*handler)(struct cli_state *, uint16_t, unsigned char)); /* The following definitions come from libsmb/cliprint.c */ |