formate
This commit is contained in:
parent
0deef5aa1e
commit
ed788d3991
|
@ -147,7 +147,6 @@ typedef struct {
|
||||||
// SEpSet* pSet; // for synchronous API
|
// SEpSet* pSet; // for synchronous API
|
||||||
} STransConnCtx;
|
} STransConnCtx;
|
||||||
|
|
||||||
|
|
||||||
#pragma pack(push, 1)
|
#pragma pack(push, 1)
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
|
@ -248,20 +247,17 @@ bool transReadComplete(SConnBuffer* connBuf);
|
||||||
|
|
||||||
int transSetConnOption(uv_tcp_t* stream);
|
int transSetConnOption(uv_tcp_t* stream);
|
||||||
|
|
||||||
|
|
||||||
void transRefSrvHandle(void* handle);
|
void transRefSrvHandle(void* handle);
|
||||||
void transUnrefSrvHandle(void* handle);
|
void transUnrefSrvHandle(void* handle);
|
||||||
|
|
||||||
void transRefCliHandle(void* handle);
|
void transRefCliHandle(void* handle);
|
||||||
void transUnrefCliHandle(void* handle);
|
void transUnrefCliHandle(void* handle);
|
||||||
|
|
||||||
|
|
||||||
void transSendRequest(void* shandle, const char* ip, uint32_t port, STransMsg* pMsg);
|
void transSendRequest(void* shandle, const char* ip, uint32_t port, STransMsg* pMsg);
|
||||||
void transSendRecv(void* shandle, const char* ip, uint32_t port, STransMsg* pMsg, STransMsg* pRsp);
|
void transSendRecv(void* shandle, const char* ip, uint32_t port, STransMsg* pMsg, STransMsg* pRsp);
|
||||||
void transSendResponse(const STransMsg* pMsg);
|
void transSendResponse(const STransMsg* pMsg);
|
||||||
int transGetConnInfo(void* thandle, STransHandleInfo* pInfo);
|
int transGetConnInfo(void* thandle, STransHandleInfo* pInfo);
|
||||||
|
|
||||||
|
|
||||||
void* transInitServer(uint32_t ip, uint32_t port, char* label, int numOfThreads, void* fp, void* shandle);
|
void* transInitServer(uint32_t ip, uint32_t port, char* label, int numOfThreads, void* fp, void* shandle);
|
||||||
void* transInitClient(uint32_t ip, uint32_t port, char* label, int numOfThreads, void* fp, void* shandle);
|
void* transInitClient(uint32_t ip, uint32_t port, char* label, int numOfThreads, void* fp, void* shandle);
|
||||||
|
|
||||||
|
|
|
@ -135,7 +135,13 @@ static void destroyThrdObj(SCliThrdObj* pThrd);
|
||||||
} \
|
} \
|
||||||
} while (0);
|
} while (0);
|
||||||
|
|
||||||
#define CONN_SET_PERSIST_BY_APP(conn) do { if (conn->persist == false) { conn->persist = true; transRefCliHandle(conn);}} while(0)
|
#define CONN_SET_PERSIST_BY_APP(conn) \
|
||||||
|
do { \
|
||||||
|
if (conn->persist == false) { \
|
||||||
|
conn->persist = true; \
|
||||||
|
transRefCliHandle(conn); \
|
||||||
|
} \
|
||||||
|
} while (0)
|
||||||
#define CONN_NO_PERSIST_BY_APP(conn) ((conn)->persist == false)
|
#define CONN_NO_PERSIST_BY_APP(conn) ((conn)->persist == false)
|
||||||
|
|
||||||
static void* cliWorkThread(void* arg);
|
static void* cliWorkThread(void* arg);
|
||||||
|
|
Loading…
Reference in New Issue