提交 df17d3c6 编写于 作者: C Cary Xu

update

上级 8f40aef2
...@@ -39,7 +39,7 @@ static FORCE_INLINE int32_t taosCloseSocket(int x) { ...@@ -39,7 +39,7 @@ static FORCE_INLINE int32_t taosCloseSocket(int x) {
x = ((int32_t)-1); x = ((int32_t)-1);
} }
if (ret != 0) { if (ret != 0) {
exit(10); assert(false);
} }
return ret; return ret;
} }
......
...@@ -568,7 +568,7 @@ static void syncClosePeerConn(SSyncPeer *pPeer) { ...@@ -568,7 +568,7 @@ static void syncClosePeerConn(SSyncPeer *pPeer) {
taosTmrStopA(&pPeer->timer); taosTmrStopA(&pPeer->timer);
if (taosCloseSocket(pPeer->syncFd) != 0) { if (taosCloseSocket(pPeer->syncFd) != 0) {
exit(4); exit(false);
} }
if (pPeer->peerFd >= 0) { if (pPeer->peerFd >= 0) {
pPeer->peerFd = -1; pPeer->peerFd = -1;
...@@ -896,7 +896,7 @@ static void syncRestartPeer(SSyncPeer *pPeer) { ...@@ -896,7 +896,7 @@ static void syncRestartPeer(SSyncPeer *pPeer) {
if (pPeer->nodeId == 0 || ret > 0 || (ret == 0 && pPeer->port > tsSyncPort)) { if (pPeer->nodeId == 0 || ret > 0 || (ret == 0 && pPeer->port > tsSyncPort)) {
sDebug("%s, check peer connection in 1000 ms", pPeer->id); sDebug("%s, check peer connection in 1000 ms", pPeer->id);
if (!taosTmrReset(syncCheckPeerConnection, SYNC_CHECK_INTERVAL, (void *)pPeer->rid, tsSyncTmrCtrl, &pPeer->timer)) { if (!taosTmrReset(syncCheckPeerConnection, SYNC_CHECK_INTERVAL, (void *)pPeer->rid, tsSyncTmrCtrl, &pPeer->timer)) {
exit(3); assert(false);
} }
} }
} }
......
...@@ -169,7 +169,7 @@ void syncFreeTcpConn(void *param) { ...@@ -169,7 +169,7 @@ void syncFreeTcpConn(void *param) {
sDebug("%p TCP connection will be closed, fd:%d", pThread, pConn->fd); sDebug("%p TCP connection will be closed, fd:%d", pThread, pConn->fd);
pConn->closedByApp = 1; pConn->closedByApp = 1;
if (shutdown(pConn->fd, SHUT_WR) != 0) { if (shutdown(pConn->fd, SHUT_WR) != 0) {
exit(2); ASSERT(false);
} }
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册