提交 eb081fc2 编写于 作者: U ubuntu

handle except

上级 f3e8c65b
...@@ -238,11 +238,17 @@ void cliHandleResp(SCliConn* conn) { ...@@ -238,11 +238,17 @@ void cliHandleResp(SCliConn* conn) {
if (CONN_NO_PERSIST_BY_APP(conn)) { if (CONN_NO_PERSIST_BY_APP(conn)) {
pMsg = transQueuePop(&conn->cliMsgs); pMsg = transQueuePop(&conn->cliMsgs);
/// uint64_t ahandle = (uint64_t)pHead->ahandle; pCtx = pMsg ? pMsg->ctx: NULL;
// CONN_GET_MSGCTX_BY_AHANDLE(conn, ahandle); if (pMsg == NULL && !CONN_NO_PERSIST_BY_APP(conn)) {
pCtx = pMsg ? pMsg->ctx : NULL; transMsg.ahandle = transCtxDumpVal(&conn->ctx, transMsg.msgType);
transMsg.ahandle = pCtx ? pCtx->ahandle : NULL; if (transMsg.ahandle == NULL) {
tDebug("cli conn %p get ahandle %p, persist: 0", conn, transMsg.ahandle); transMsg.ahandle = transCtxDumpBrokenlinkVal(&conn->ctx, (int32_t*)&(transMsg.msgType));
}
tDebug("cli conn %p construct ahandle %p, persist: 0", conn, transMsg.ahandle);
} else {
transMsg.ahandle = pCtx ? pCtx->ahandle : NULL;
tDebug("cli conn %p get ahandle %p, persist: 0", conn, transMsg.ahandle);
}
} else { } else {
uint64_t ahandle = (uint64_t)pHead->ahandle; uint64_t ahandle = (uint64_t)pHead->ahandle;
CONN_GET_MSGCTX_BY_AHANDLE(conn, ahandle); CONN_GET_MSGCTX_BY_AHANDLE(conn, ahandle);
...@@ -414,8 +420,8 @@ static SCliConn* getConnFromPool(void* pool, char* ip, uint32_t port) { ...@@ -414,8 +420,8 @@ static SCliConn* getConnFromPool(void* pool, char* ip, uint32_t port) {
} }
queue* h = QUEUE_HEAD(&plist->conn); queue* h = QUEUE_HEAD(&plist->conn);
QUEUE_REMOVE(h); QUEUE_REMOVE(h);
SCliConn* conn = QUEUE_DATA(h, SCliConn, conn); SCliConn* conn = QUEUE_DATA(h, SCliConn, conn);
conn->status = ConnNormal;
QUEUE_INIT(&conn->conn); QUEUE_INIT(&conn->conn);
return conn; return conn;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册