From f7529fffce6de70a6914e17f91876d721e02b219 Mon Sep 17 00:00:00 2001 From: Samuel Cabrero Date: Mon, 18 Feb 2019 21:04:00 +0100 Subject: [PATCH] s3:rpc_server: Make make_external_rpc_pipe_p and np_proxy_state private This function and struct is not used outside rpc_ncacn_np.c Signed-off-by: Samuel Cabrero Reviewed-by: Andreas Schneider Reviewed-by: Stefan Metzmacher --- source3/rpc_server/rpc_ncacn_np.c | 25 ++++++++++++++++++++----- source3/rpc_server/rpc_ncacn_np.h | 14 -------------- 2 files changed, 20 insertions(+), 19 deletions(-) diff --git a/source3/rpc_server/rpc_ncacn_np.c b/source3/rpc_server/rpc_ncacn_np.c index da22c24b638..6f28ba13c64 100644 --- a/source3/rpc_server/rpc_ncacn_np.c +++ b/source3/rpc_server/rpc_ncacn_np.c @@ -51,6 +51,21 @@ static NTSTATUS make_internal_rpc_pipe_p(TALLOC_CTX *mem_ctx, struct messaging_context *msg_ctx, struct pipes_struct **p); +struct np_proxy_state { + uint16_t file_type; + uint16_t device_state; + uint64_t allocation_size; + struct tstream_context *npipe; + struct tevent_queue *read_queue; + struct tevent_queue *write_queue; +}; + +static struct np_proxy_state *make_external_rpc_pipe_p(TALLOC_CTX *mem_ctx, + const char *pipe_name, + const struct tsocket_address *remote_address, + const struct tsocket_address *local_address, + const struct auth_session_info *session_info); + static struct npa_state *npa_state_init(TALLOC_CTX *mem_ctx) { struct npa_state *npa; @@ -821,10 +836,10 @@ out: return status; } -struct np_proxy_state *make_external_rpc_pipe_p(TALLOC_CTX *mem_ctx, +static struct np_proxy_state *make_external_rpc_pipe_p(TALLOC_CTX *mem_ctx, const char *pipe_name, - const struct tsocket_address *remote_client_address, - const struct tsocket_address *local_server_address, + const struct tsocket_address *remote_address, + const struct tsocket_address *local_address, const struct auth_session_info *session_info) { struct np_proxy_state *result; @@ -891,9 +906,9 @@ struct np_proxy_state *make_external_rpc_pipe_p(TALLOC_CTX *mem_ctx, subreq = tstream_npa_connect_send(talloc_tos(), ev, socket_np_dir, pipe_name, - remote_client_address, + remote_address, NULL, /* client_name */ - local_server_address, + local_address, NULL, /* server_name */ session_info_t); if (subreq == NULL) { diff --git a/source3/rpc_server/rpc_ncacn_np.h b/source3/rpc_server/rpc_ncacn_np.h index e428dda74b3..705306c7793 100644 --- a/source3/rpc_server/rpc_ncacn_np.h +++ b/source3/rpc_server/rpc_ncacn_np.h @@ -55,20 +55,6 @@ NTSTATUS make_internal_rpc_pipe_socketpair( const struct auth_session_info *session_info, struct npa_state **pnpa); -struct np_proxy_state { - uint16_t file_type; - uint16_t device_state; - uint64_t allocation_size; - struct tstream_context *npipe; - struct tevent_queue *read_queue; - struct tevent_queue *write_queue; -}; - -struct np_proxy_state *make_external_rpc_pipe_p(TALLOC_CTX *mem_ctx, - const char *pipe_name, - const struct tsocket_address *remote_client_address, - const struct tsocket_address *local_server_address, - const struct auth_session_info *session_info); NTSTATUS rpcint_binding_handle(TALLOC_CTX *mem_ctx, const struct ndr_interface_table *ndr_table, const struct tsocket_address *remote_address, -- 2.47.3