s3:dcerpc Remove unused structure and functions
authorSimo Sorce <idra@samba.org>
Thu, 8 Jul 2010 05:48:05 +0000 (01:48 -0400)
committerSimo Sorce <idra@samba.org>
Thu, 8 Jul 2010 05:48:05 +0000 (01:48 -0400)
source3/include/proto.h
source3/include/rpc_dce.h
source3/rpc_parse/parse_rpc.c

index 90afdd1fa67d8ceb5dc8eb1ee4ed78701e02f045..d08dc59ecba8655ab5c9990d47539bfddbc3ee71 100644 (file)
@@ -5078,8 +5078,6 @@ const char *get_pipe_name_from_syntax(TALLOC_CTX *mem_ctx,
 void init_rpc_hdr(RPC_HDR *hdr, enum dcerpc_pkt_type pkt_type, uint8 flags,
                                uint32 call_id, int data_len, int auth_len);
 bool smb_io_rpc_hdr(const char *desc,  RPC_HDR *rpc, prs_struct *ps, int depth);
-bool smb_io_rpc_context(const char *desc, struct dcerpc_ctx_list *rpc_ctx, prs_struct *ps, int depth);
-bool smb_io_rpc_hdr_rb(const char *desc, RPC_HDR_RB *rpc, prs_struct *ps, int depth);
 NTSTATUS dcerpc_pull_dcerpc_bind(TALLOC_CTX *mem_ctx,
                                 const DATA_BLOB *blob,
                                 struct dcerpc_bind *r);
index 03d1e32cca24083f12a44c22727ce45c3e643299..ade4728d230903715f26c51b3a41ef893c7b6048 100644 (file)
@@ -107,13 +107,6 @@ typedef struct rpc_hdr_auth_info {
 
 #define RPC_HDR_AUTH_LEN 8
 
-/* RPC_BIND_REQ - ms req bind */
-typedef struct rpc_bind_req_info {
-       RPC_HDR_BBA bba;
-       uint8 num_contexts;    /* the number of contexts */
-       struct dcerpc_ctx_list *rpc_context;
-} RPC_HDR_RB;
-
 /* 
  * The following length is 8 bytes RPC_HDR_BBA_LEN + 
  * 4 bytes size of context count +
index 90e939715e39bea416a9fe37d353506da2272fe5..623e8678013845f11a0052e672a73fd8169b3bb2 100644 (file)
@@ -189,47 +189,6 @@ static bool smb_io_rpc_hdr_bba(const char *desc,  RPC_HDR_BBA *rpc, prs_struct *
        return True;
 }
 
-/*******************************************************************
- Reads or writes a struct dcerpc_ctx_list structure.
-********************************************************************/
-
-bool smb_io_rpc_context(const char *desc, struct dcerpc_ctx_list *rpc_ctx, prs_struct *ps, int depth)
-{
-       int i;
-
-       if (rpc_ctx == NULL)
-               return False;
-
-       if(!prs_align(ps))
-               return False;
-       if(!prs_uint16("context_id  ", ps, depth, &rpc_ctx->context_id ))
-               return False;
-       if(!prs_uint8 ("num_transfer_syntaxes", ps, depth, &rpc_ctx->num_transfer_syntaxes))
-               return False;
-
-       /* num_transfer_syntaxes must not be zero. */
-       if (rpc_ctx->num_transfer_syntaxes == 0)
-               return False;
-
-       if(!smb_io_rpc_iface("", &rpc_ctx->abstract_syntax, ps, depth))
-               return False;
-
-       if (UNMARSHALLING(ps)) {
-               rpc_ctx->transfer_syntaxes =
-                       PRS_ALLOC_MEM(ps, struct ndr_syntax_id,
-                                       rpc_ctx->num_transfer_syntaxes);
-               if (!rpc_ctx->transfer_syntaxes) {
-                       return False;
-               }
-       }
-
-       for (i = 0; i < rpc_ctx->num_transfer_syntaxes; i++ ) {
-               if (!smb_io_rpc_iface("", &rpc_ctx->transfer_syntaxes[i], ps, depth))
-                       return False;
-       }
-       return True;
-} 
-
 NTSTATUS dcerpc_pull_dcerpc_bind(TALLOC_CTX *mem_ctx,
                                 const DATA_BLOB *blob,
                                 struct dcerpc_bind *r)
@@ -245,46 +204,6 @@ NTSTATUS dcerpc_pull_dcerpc_bind(TALLOC_CTX *mem_ctx,
        return NT_STATUS_OK;
 }
 
-/*******************************************************************
- Reads or writes an RPC_HDR_RB structure.
-********************************************************************/
-
-bool smb_io_rpc_hdr_rb(const char *desc, RPC_HDR_RB *rpc, prs_struct *ps, int depth)
-{
-       int i;
-       
-       if (rpc == NULL)
-               return False;
-
-       prs_debug(ps, depth, desc, "smb_io_rpc_hdr_rb");
-       depth++;
-
-       if(!smb_io_rpc_hdr_bba("", &rpc->bba, ps, depth))
-               return False;
-
-       if(!prs_uint8("num_contexts", ps, depth, &rpc->num_contexts))
-               return False;
-
-       /* 3 pad bytes following - will be mopped up by the prs_align in smb_io_rpc_context(). */
-
-       /* num_contexts must not be zero. */
-       if (rpc->num_contexts == 0)
-               return False;
-
-       if (UNMARSHALLING(ps)) {
-               if (!(rpc->rpc_context = PRS_ALLOC_MEM(ps, struct dcerpc_ctx_list, rpc->num_contexts))) {
-                       return False;
-               }
-       }
-
-       for (i = 0; i < rpc->num_contexts; i++ ) {
-               if (!smb_io_rpc_context("", &rpc->rpc_context[i], ps, depth))
-                       return False;
-       }
-
-       return True;
-}
-
 /*******************************************************************
  Inits an RPC_RESULTS structure.