libsmb: Remove unused cli_smb2_get_reparse_point_fnum_send/recv
authorVolker Lendecke <vl@samba.org>
Thu, 29 Sep 2022 10:41:54 +0000 (12:41 +0200)
committerJeremy Allison <jra@samba.org>
Mon, 3 Oct 2022 20:03:32 +0000 (20:03 +0000)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/libsmb/cli_smb2_fnum.c
source3/libsmb/cli_smb2_fnum.h

index 7cb06335a77e8da5c078c183632468e95df32db9..fc576550997ee5db203da287fa2c297029ab4b9d 100644 (file)
@@ -4970,103 +4970,6 @@ NTSTATUS cli_smb2_set_reparse_point_fnum_recv(struct tevent_req *req)
         return tevent_req_simple_recv_ntstatus(req);
 }
 
-struct cli_smb2_get_reparse_point_fnum_state {
-       struct cli_state *cli;
-       uint16_t fnum;
-       struct smb2_hnd *ph;
-       DATA_BLOB output_buffer;
-};
-
-static void cli_smb2_get_reparse_point_fnum_done(struct tevent_req *subreq);
-
-struct tevent_req *cli_smb2_get_reparse_point_fnum_send(
-                               TALLOC_CTX *mem_ctx,
-                               struct tevent_context *ev,
-                               struct cli_state *cli,
-                               uint16_t fnum)
-{
-       struct tevent_req *req, *subreq;
-       struct cli_smb2_get_reparse_point_fnum_state *state = NULL;
-       NTSTATUS status;
-
-       req = tevent_req_create(mem_ctx, &state,
-                               struct cli_smb2_get_reparse_point_fnum_state);
-       if (req == NULL) {
-               return NULL;
-       }
-
-       state->cli = cli;
-       state->fnum = fnum;
-
-       status = map_fnum_to_smb2_handle(cli, fnum, &state->ph);
-       if (tevent_req_nterror(req, status)) {
-               return tevent_req_post(req, ev);
-       }
-
-       subreq = smb2cli_ioctl_send(state, ev, state->cli->conn,
-                       state->cli->timeout,
-                       state->cli->smb2.session,
-                       state->cli->smb2.tcon,
-                       state->ph->fid_persistent, /* in_fid_persistent */
-                       state->ph->fid_volatile, /* in_fid_volatile */
-                       FSCTL_GET_REPARSE_POINT,
-                       0, /* in_max_input_length */
-                       NULL,
-                       64*1024,
-                       NULL,
-                       SMB2_IOCTL_FLAG_IS_FSCTL);
-
-       if (tevent_req_nomem(subreq, req)) {
-               return tevent_req_post(req, ev);
-       }
-       tevent_req_set_callback(subreq,
-                               cli_smb2_get_reparse_point_fnum_done,
-                               req);
-
-       return req;
-}
-
-static void cli_smb2_get_reparse_point_fnum_done(struct tevent_req *subreq)
-{
-       struct tevent_req *req = tevent_req_callback_data(
-               subreq, struct tevent_req);
-       struct cli_smb2_get_reparse_point_fnum_state *state = tevent_req_data(
-               req, struct cli_smb2_get_reparse_point_fnum_state);
-       struct cli_state *cli = state->cli;
-       NTSTATUS status;
-
-       status = smb2cli_ioctl_recv(subreq, state,
-                               NULL,
-                               &state->output_buffer);
-       TALLOC_FREE(subreq);
-       if (tevent_req_nterror(req, status)) {
-               cli->raw_status = status;
-               return;
-       }
-       tevent_req_done(req);
-}
-
-NTSTATUS cli_smb2_get_reparse_point_fnum_recv(struct tevent_req *req,
-                               TALLOC_CTX *mem_ctx,
-                               DATA_BLOB *output)
-{
-       struct cli_smb2_get_reparse_point_fnum_state *state = tevent_req_data(
-               req, struct cli_smb2_get_reparse_point_fnum_state);
-
-       if (tevent_req_is_nterror(req, &state->cli->raw_status)) {
-               NTSTATUS status = state->cli->raw_status;
-               tevent_req_received(req);
-               return status;
-       }
-       *output = data_blob_dup_talloc(mem_ctx, state->output_buffer);
-       if (output->data == NULL) {
-               tevent_req_received(req);
-               return NT_STATUS_NO_MEMORY;
-       }
-       tevent_req_received(req);
-       return NT_STATUS_OK;
-}
-
 struct cli_smb2_fsctl_state {
        DATA_BLOB out;
 };
index e2921c2bded23d72c0792eb8b416b6f4644d48fa..2b1524a676edfb3ecfc1abdac99ac5a3528d975c 100644 (file)
@@ -319,15 +319,6 @@ struct tevent_req *cli_smb2_set_reparse_point_fnum_send(
                        DATA_BLOB in_buf);
 NTSTATUS cli_smb2_set_reparse_point_fnum_recv(struct tevent_req *req);
 
-struct tevent_req *cli_smb2_get_reparse_point_fnum_send(
-                       TALLOC_CTX *mem_ctx,
-                       struct tevent_context *ev,
-                       struct cli_state *cli,
-                       uint16_t fnum);
-NTSTATUS cli_smb2_get_reparse_point_fnum_recv(struct tevent_req *req,
-                       TALLOC_CTX *mem_ctx,
-                       DATA_BLOB *output);
-
 struct tevent_req *cli_smb2_fsctl_send(
        TALLOC_CTX *mem_ctx,
        struct tevent_context *ev,