From 5bfb579f9ab849ed4296d7a6a9bb1954a73cec35 Mon Sep 17 00:00:00 2001 From: Mike McCormack Date: Fri, 21 Apr 2006 16:07:35 +0900 Subject: [PATCH] rpcrt4: Add a stub transport layer for ncacn_ip_tcp. --- dlls/rpcrt4/rpc_transport.c | 54 +++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 52 insertions(+), 2 deletions(-) diff --git a/dlls/rpcrt4/rpc_transport.c b/dlls/rpcrt4/rpc_transport.c index ab7890dcf05..98d8006b054 100644 --- a/dlls/rpcrt4/rpc_transport.c +++ b/dlls/rpcrt4/rpc_transport.c @@ -45,8 +45,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(rpc); -static struct protseq_ops *rpcrt4_get_protseq_ops(const char *protseq); - typedef struct _RpcConnection_np { RpcConnection common; @@ -226,6 +224,49 @@ static int rpcrt4_conn_np_close(RpcConnection *Connection) return 0; } +typedef struct _RpcConnection_tcp +{ + RpcConnection common; +} RpcConnection_tcp; + +static RpcConnection *rpcrt4_conn_tcp_alloc(void) +{ + return HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(RpcConnection_tcp)); +} + +static RPC_STATUS rpcrt4_ncacn_ip_tcp_open(RpcConnection* Connection) +{ + FIXME("(%s, %s) unimplemented\n", Connection->NetworkAddr, Connection->Endpoint); + return RPC_S_SERVER_UNAVAILABLE; +} + +static HANDLE rpcrt4_conn_tcp_get_wait_handle(RpcConnection *Connection) +{ + return NULL; +} + +static RPC_STATUS rpcrt4_conn_tcp_handoff(RpcConnection *old_conn, RpcConnection *new_conn) +{ + return RPC_S_SERVER_UNAVAILABLE; +} + +static int rpcrt4_conn_tcp_read(RpcConnection *Connection, + void *buffer, unsigned int count) +{ + return -1; +} + +static int rpcrt4_conn_tcp_write(RpcConnection *Connection, + const void *buffer, unsigned int count) +{ + return -1; +} + +static int rpcrt4_conn_tcp_close(RpcConnection *Connection) +{ + return -1; +} + struct protseq_ops protseq_list[] = { { "ncacn_np", rpcrt4_conn_np_alloc, @@ -245,6 +286,15 @@ struct protseq_ops protseq_list[] = { rpcrt4_conn_np_write, rpcrt4_conn_np_close, }, + { "ncacn_ip_tcp", + rpcrt4_conn_tcp_alloc, + rpcrt4_ncacn_ip_tcp_open, + rpcrt4_conn_tcp_get_wait_handle, + rpcrt4_conn_tcp_handoff, + rpcrt4_conn_tcp_read, + rpcrt4_conn_tcp_write, + rpcrt4_conn_tcp_close, + } }; #define MAX_PROTSEQ (sizeof protseq_list / sizeof protseq_list[0]) -- 2.11.4.GIT