Fix make error.

This commit is contained in:
xiao-77 2024-12-16 13:28:31 +08:00
parent 0bf2280223
commit 320c291576
1 changed files with 3 additions and 3 deletions

View File

@ -14,8 +14,8 @@
*/
#define _DEFAULT_SOURCE
#include "tenv.h"
#include "tconfig.h"
#include "tenv.h"
static char toLowChar(char c) { return (c > 'Z' || c < 'A' ? c : (c - 'A' + 'a')); }
@ -55,7 +55,7 @@ int32_t taosEnvToCfg(const char *envStr, char *cfgStr,int32_t cfgStrLen) {
return TSDB_CODE_INVALID_PARA;
}
if (cfgStr != envStr) {
tstrncpy(cfgStr, envStr, strlen(envStr) + 1);
tstrncpy(cfgStr, envStr, cfgStrLen);
}
char *p = strchr(cfgStr, '=');