Merge pull request #17998 from taosdata/fix/liao_cov
fix(query): fix syntax errors.
This commit is contained in:
commit
be9a32fcfd
|
@ -131,7 +131,8 @@ static int32_t udfSpawnUdfd(SUdfdData *pData) {
|
||||||
|
|
||||||
char udfdPathLdLib[1024] = {0};
|
char udfdPathLdLib[1024] = {0};
|
||||||
size_t udfdLdLibPathLen = strlen(tsUdfdLdLibPath);
|
size_t udfdLdLibPathLen = strlen(tsUdfdLdLibPath);
|
||||||
strncpy(udfdPathLdLib, tsUdfdLdLibPath, udfdLdLibPathLen);
|
strncpy(udfdPathLdLib, tsUdfdLdLibPath, tListLen(udfdPathLdLib));
|
||||||
|
|
||||||
udfdPathLdLib[udfdLdLibPathLen] = ':';
|
udfdPathLdLib[udfdLdLibPathLen] = ':';
|
||||||
strncpy(udfdPathLdLib + udfdLdLibPathLen + 1, pathTaosdLdLib, sizeof(udfdPathLdLib) - udfdLdLibPathLen - 1);
|
strncpy(udfdPathLdLib + udfdLdLibPathLen + 1, pathTaosdLdLib, sizeof(udfdPathLdLib) - udfdLdLibPathLen - 1);
|
||||||
if (udfdLdLibPathLen + taosdLdLibPathLen < 1024) {
|
if (udfdLdLibPathLen + taosdLdLibPathLen < 1024) {
|
||||||
|
|
|
@ -317,14 +317,14 @@ static void taosGetLogFileName(char *fn) {
|
||||||
for (int32_t i = 0; i < tsLogObj.fileNum; i++) {
|
for (int32_t i = 0; i < tsLogObj.fileNum; i++) {
|
||||||
char fileName[LOG_FILE_NAME_LEN];
|
char fileName[LOG_FILE_NAME_LEN];
|
||||||
|
|
||||||
sprintf(fileName, "%s%d.0", fn, i);
|
snprintf(fileName, LOG_FILE_NAME_LEN, "%s%d.0", fn, i);
|
||||||
bool file1open = taosCheckFileIsOpen(fileName);
|
bool file1open = taosCheckFileIsOpen(fileName);
|
||||||
|
|
||||||
sprintf(fileName, "%s%d.1", fn, i);
|
snprintf(fileName, LOG_FILE_NAME_LEN, "%s%d.1", fn, i);
|
||||||
bool file2open = taosCheckFileIsOpen(fileName);
|
bool file2open = taosCheckFileIsOpen(fileName);
|
||||||
|
|
||||||
if (!file1open && !file2open) {
|
if (!file1open && !file2open) {
|
||||||
sprintf(tsLogObj.logName, "%s%d", fn, i);
|
snprintf(tsLogObj.logName, LOG_FILE_NAME_LEN, "%s%d", fn, i);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -598,7 +598,7 @@ static int32_t taosPushLogBuffer(SLogBuff *pLogBuf, const char *msg, int32_t msg
|
||||||
remainSize = (start > end) ? (start - end - 1) : (start + LOG_BUF_SIZE(pLogBuf) - end - 1);
|
remainSize = (start > end) ? (start - end - 1) : (start + LOG_BUF_SIZE(pLogBuf) - end - 1);
|
||||||
|
|
||||||
if (lostLine > 0) {
|
if (lostLine > 0) {
|
||||||
sprintf(tmpBuf, "...Lost %" PRId64 " lines here...\n", lostLine);
|
snprintf(tmpBuf, tListLen(tmpBuf), "...Lost %" PRId64 " lines here...\n", lostLine);
|
||||||
tmpBufLen = (int32_t)strlen(tmpBuf);
|
tmpBufLen = (int32_t)strlen(tmpBuf);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue