Merge pull request #1002 from taosdata/feature/lihui

[#974]
This commit is contained in:
slguan 2019-12-24 16:55:07 +08:00 committed by GitHub
commit af4b51cc84
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -447,6 +447,7 @@ void *taosInitTcpServer(char *ip, uint16_t port, char *label, int numOfThreads,
return (void *)pServerObj; return (void *)pServerObj;
} }
#if 0
void taosListTcpConnection(void *handle, char *buffer) { void taosListTcpConnection(void *handle, char *buffer) {
SServerObj *pServerObj; SServerObj *pServerObj;
SThreadObj *pThreadObj; SThreadObj *pThreadObj;
@ -468,7 +469,7 @@ void taosListTcpConnection(void *handle, char *buffer) {
msg = msg + strlen(msg); msg = msg + strlen(msg);
pFdObj = pThreadObj->pHead; pFdObj = pThreadObj->pHead;
while (pFdObj) { while (pFdObj) {
sprintf(" ip:%s port:%hu\n", pFdObj->ipstr, pFdObj->port); sprintf(msg, " ip:%s port:%hu\n", pFdObj->ipstr, pFdObj->port);
msg = msg + strlen(msg); msg = msg + strlen(msg);
numOfFds++; numOfFds++;
numOfConns++; numOfConns++;
@ -486,6 +487,7 @@ void taosListTcpConnection(void *handle, char *buffer) {
return; return;
} }
#endif
int taosSendTcpServerData(uint32_t ip, uint16_t port, char *data, int len, void *chandle) { int taosSendTcpServerData(uint32_t ip, uint16_t port, char *data, int len, void *chandle) {
SFdObj *pFdObj = (SFdObj *)chandle; SFdObj *pFdObj = (SFdObj *)chandle;