fix invalid packet
This commit is contained in:
parent
1a449a51a1
commit
e1ae5bc7f8
|
@ -75,7 +75,7 @@ int32_t tsMonitorMaxLogs = 100;
|
|||
bool tsMonitorComp = false;
|
||||
|
||||
// telem
|
||||
bool tsEnableTelem = false;
|
||||
bool tsEnableTelem = true;
|
||||
int32_t tsTelemInterval = 86400;
|
||||
char tsTelemServer[TSDB_FQDN_LEN] = "telemetry.taosdata.com";
|
||||
uint16_t tsTelemPort = 80;
|
||||
|
@ -166,7 +166,7 @@ int32_t tsTtlPushInterval = 86400;
|
|||
int32_t tsGrantHBInterval = 60;
|
||||
|
||||
#ifndef _STORAGE
|
||||
int32_t taosSetTfsCfg(SConfig *pCfg) {
|
||||
int32_t taosSetTfsCfg(SConfig *pCfg) {
|
||||
SConfigItem *pItem = cfgGetItem(pCfg, "dataDir");
|
||||
memset(tsDataDir, 0, PATH_MAX);
|
||||
|
||||
|
@ -180,7 +180,7 @@ int32_t taosSetTfsCfg(SConfig *pCfg) {
|
|||
uError("failed to create dataDir:%s", tsDataDir);
|
||||
return -1;
|
||||
}
|
||||
return 0;
|
||||
return 0;
|
||||
}
|
||||
#else
|
||||
int32_t taosSetTfsCfg(SConfig *pCfg);
|
||||
|
|
|
@ -152,15 +152,15 @@ static void clientConnCb(uv_connect_t* req, int32_t status) {
|
|||
}
|
||||
|
||||
static int32_t taosBuildDstAddr(const char* server, uint16_t port, struct sockaddr_in* dest) {
|
||||
uint32_t ipv4 = taosGetIpv4FromFqdn(server);
|
||||
if (ipv4 == 0xffffffff) {
|
||||
uint32_t ip = taosGetIpv4FromFqdn(server);
|
||||
if (ip == 0xffffffff) {
|
||||
terrno = TAOS_SYSTEM_ERROR(errno);
|
||||
uError("http-report failed to get http server:%s ip since %s", server, terrstr());
|
||||
return -1;
|
||||
}
|
||||
char ipv4Buf[128] = {0};
|
||||
tinet_ntoa(ipv4Buf, ipv4);
|
||||
uv_ip4_addr(ipv4Buf, port, dest);
|
||||
char buf[128] = {0};
|
||||
tinet_ntoa(buf, ip);
|
||||
uv_ip4_addr(buf, port, dest);
|
||||
return 0;
|
||||
}
|
||||
int32_t taosSendHttpReport(const char* server, uint16_t port, char* pCont, int32_t contLen, EHttpCompFlag flag) {
|
||||
|
|
Loading…
Reference in New Issue