提交 868cf83c 编写于 作者: sangshuduo's avatar sangshuduo

chore: prepare for string passing

上级 2673b6a5
...@@ -109,8 +109,8 @@ static int32_t dmStartNodes(SDnode *pDnode) { ...@@ -109,8 +109,8 @@ static int32_t dmStartNodes(SDnode *pDnode) {
} }
} }
dInfo("TDengine initialized successfully"); dInfo("The daemon initialized successfully");
dmReportStartup("TDengine", "initialized successfully"); dmReportStartup("The daemon", "initialized successfully");
return 0; return 0;
} }
...@@ -142,7 +142,7 @@ int32_t dmRunDnode(SDnode *pDnode) { ...@@ -142,7 +142,7 @@ int32_t dmRunDnode(SDnode *pDnode) {
while (1) { while (1) {
if (pDnode->stop) { if (pDnode->stop) {
dInfo("TDengine is about to stop"); dInfo("The daemon is about to stop");
dmSetStatus(pDnode, DND_STAT_STOPPED); dmSetStatus(pDnode, DND_STAT_STOPPED);
dmStopNodes(pDnode); dmStopNodes(pDnode);
dmCloseNodes(pDnode); dmCloseNodes(pDnode);
......
...@@ -71,7 +71,7 @@ char *taosCharsetReplace(char *charsetstr) { ...@@ -71,7 +71,7 @@ char *taosCharsetReplace(char *charsetstr) {
* seems does not response as expected. * seems does not response as expected.
* *
* In some Linux systems, setLocale(LC_CTYPE, "") may return NULL, in which case the launch of * In some Linux systems, setLocale(LC_CTYPE, "") may return NULL, in which case the launch of
* both the TDengine Server and the Client may be interrupted. * both the Server and the Client may be interrupted.
* *
* In case that the setLocale failed to be executed, the right charset needs to be set. * In case that the setLocale failed to be executed, the right charset needs to be set.
*/ */
......
...@@ -217,7 +217,7 @@ void taosReleaseConv(int32_t idx, iconv_t conv, ConvType type) { ...@@ -217,7 +217,7 @@ void taosReleaseConv(int32_t idx, iconv_t conv, ConvType type) {
bool taosMbsToUcs4(const char *mbs, size_t mbsLength, TdUcs4 *ucs4, int32_t ucs4_max_len, int32_t *len) { bool taosMbsToUcs4(const char *mbs, size_t mbsLength, TdUcs4 *ucs4, int32_t ucs4_max_len, int32_t *len) {
#ifdef DISALLOW_NCHAR_WITHOUT_ICONV #ifdef DISALLOW_NCHAR_WITHOUT_ICONV
printf("Nchar cannot be read and written without iconv, please install iconv library and recompile TDengine.\n"); printf("Nchar cannot be read and written without iconv, please install iconv library and recompile.\n");
return -1; return -1;
#else #else
memset(ucs4, 0, ucs4_max_len); memset(ucs4, 0, ucs4_max_len);
...@@ -245,7 +245,7 @@ bool taosMbsToUcs4(const char *mbs, size_t mbsLength, TdUcs4 *ucs4, int32_t ucs4 ...@@ -245,7 +245,7 @@ bool taosMbsToUcs4(const char *mbs, size_t mbsLength, TdUcs4 *ucs4, int32_t ucs4
int32_t taosUcs4ToMbs(TdUcs4 *ucs4, int32_t ucs4_max_len, char *mbs) { int32_t taosUcs4ToMbs(TdUcs4 *ucs4, int32_t ucs4_max_len, char *mbs) {
#ifdef DISALLOW_NCHAR_WITHOUT_ICONV #ifdef DISALLOW_NCHAR_WITHOUT_ICONV
printf("Nchar cannot be read and written without iconv, please install iconv library and recompile TDengine.\n"); printf("Nchar cannot be read and written without iconv, please install iconv library and recompile.\n");
return -1; return -1;
#else #else
...@@ -263,7 +263,7 @@ int32_t taosUcs4ToMbs(TdUcs4 *ucs4, int32_t ucs4_max_len, char *mbs) { ...@@ -263,7 +263,7 @@ int32_t taosUcs4ToMbs(TdUcs4 *ucs4, int32_t ucs4_max_len, char *mbs) {
} }
bool taosValidateEncodec(const char *encodec) { bool taosValidateEncodec(const char *encodec) {
#ifdef DISALLOW_NCHAR_WITHOUT_ICONV #ifdef DISALLOW_NCHAR_WITHOUT_ICONV
printf("Nchar cannot be read and written without iconv, please install iconv library and recompile TDengine.\n"); printf("Nchar cannot be read and written without iconv, please install iconv library and recompile.\n");
return true; return true;
#else #else
iconv_t cd = iconv_open(encodec, DEFAULT_UNICODE_ENCODEC); iconv_t cd = iconv_open(encodec, DEFAULT_UNICODE_ENCODEC);
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
#define TAOS_CONSOLE_PROMPT_HEADER "taos> " #define TAOS_CONSOLE_PROMPT_HEADER "taos> "
#define TAOS_CONSOLE_PROMPT_CONTINUE " -> " #define TAOS_CONSOLE_PROMPT_CONTINUE " -> "
#define SHELL_HOST "TDengine server FQDN to connect. The default host is localhost." #define SHELL_HOST "The server FQDN to connect. The default host is localhost."
#define SHELL_PORT "The TCP/IP port number to use for the connection." #define SHELL_PORT "The TCP/IP port number to use for the connection."
#define SHELL_USER "The user name to use when connecting to the server." #define SHELL_USER "The user name to use when connecting to the server."
#define SHELL_PASSWORD "The password to use when connecting to the server." #define SHELL_PASSWORD "The password to use when connecting to the server."
......
...@@ -75,7 +75,7 @@ void shellGetPrevCharSize(const char *str, int32_t pos, int32_t *size, int32_t * ...@@ -75,7 +75,7 @@ void shellGetPrevCharSize(const char *str, int32_t pos, int32_t *size, int32_t *
} }
taosMbToWchar(&wc, str + pos, MB_CUR_MAX); taosMbToWchar(&wc, str + pos, MB_CUR_MAX);
// assert(rc == *size); // it will be core, if str is encode by utf8 and taos charset is gbk // assert(rc == *size); // it will be core, if str is encode by utf8 and charset is gbk
*width = taosWcharWidth(wc); *width = taosWcharWidth(wc);
} }
......
...@@ -50,19 +50,19 @@ bool shellRegexMatch(const char *s, const char *reg, int32_t cflags) { ...@@ -50,19 +50,19 @@ bool shellRegexMatch(const char *s, const char *reg, int32_t cflags) {
int32_t shellCheckIntSize() { int32_t shellCheckIntSize() {
if (sizeof(int8_t) != 1) { if (sizeof(int8_t) != 1) {
printf("taos int8 size is %d(!= 1)", (int)sizeof(int8_t)); printf("int8 size is %d(!= 1)", (int)sizeof(int8_t));
return -1; return -1;
} }
if (sizeof(int16_t) != 2) { if (sizeof(int16_t) != 2) {
printf("taos int16 size is %d(!= 2)", (int)sizeof(int16_t)); printf("int16 size is %d(!= 2)", (int)sizeof(int16_t));
return -1; return -1;
} }
if (sizeof(int32_t) != 4) { if (sizeof(int32_t) != 4) {
printf("taos int32 size is %d(!= 4)", (int)sizeof(int32_t)); printf("int32 size is %d(!= 4)", (int)sizeof(int32_t));
return -1; return -1;
} }
if (sizeof(int64_t) != 8) { if (sizeof(int64_t) != 8) {
printf("taos int64 size is %d(!= 8)", (int)sizeof(int64_t)); printf("int64 size is %d(!= 8)", (int)sizeof(int64_t));
return -1; return -1;
} }
return 0; return 0;
...@@ -80,7 +80,7 @@ void shellGenerateAuth() { ...@@ -80,7 +80,7 @@ void shellGenerateAuth() {
void shellDumpConfig() { void shellDumpConfig() {
SConfig *pCfg = taosGetCfg(); SConfig *pCfg = taosGetCfg();
if (pCfg == NULL) { if (pCfg == NULL) {
printf("TDengine read global config failed!\r\n"); printf("read global config failed!\r\n");
} else { } else {
cfgDumpCfg(pCfg, 1, true); cfgDumpCfg(pCfg, 1, true);
} }
......
...@@ -235,7 +235,7 @@ void shellRunSingleCommandWebsocketImp(char *command) { ...@@ -235,7 +235,7 @@ void shellRunSingleCommandWebsocketImp(char *command) {
if (reconnectNum == 0) { if (reconnectNum == 0) {
continue; continue;
} else { } else {
fprintf(stderr, "TDengine server is disconnected, will try to reconnect\n"); fprintf(stderr, "The server is disconnected, will try to reconnect\n");
} }
return; return;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册