提交 92ab9d9d 编写于 作者: Z zhaoyanggh

arm32 compile

上级 f9893f92
...@@ -591,7 +591,7 @@ void setupForAnsiEscape(void); ...@@ -591,7 +591,7 @@ void setupForAnsiEscape(void);
int taosRandom(); int taosRandom();
int testMetaFile(); int testMetaFile();
int insertTestProcess(); int insertTestProcess();
int printfInsertMeta(); void printfInsertMeta();
void printfInsertMetaToFile(FILE *fp); void printfInsertMetaToFile(FILE *fp);
void prompt(); void prompt();
void postFreeResource(); void postFreeResource();
......
...@@ -2808,8 +2808,7 @@ static int execStbBindParamBatch(threadInfo *pThreadInfo, char *tableName, ...@@ -2808,8 +2808,7 @@ static int execStbBindParamBatch(threadInfo *pThreadInfo, char *tableName,
param->buffer_type = data_type; param->buffer_type = data_type;
param->length = calloc(1, sizeof(int32_t) * thisBatch); param->length = calloc(1, sizeof(int32_t) * thisBatch);
if (param->length == NULL) { if (param->length == NULL) {
errorPrint("failed to allocate %" PRIu64 " size memory\n", errorPrint("%s", "failed to allocate memory\n");
sizeof(int32_t) * thisBatch);
return -1; return -1;
} }
...@@ -4542,10 +4541,14 @@ int startMultiThreadInsertData(int threads, char *db_name, char *precision, ...@@ -4542,10 +4541,14 @@ int startMultiThreadInsertData(int threads, char *db_name, char *precision,
int insertTestProcess() { int insertTestProcess() {
int32_t code = -1; int32_t code = -1;
if (printfInsertMeta()) { char * cmdBuffer = calloc(1, BUFFER_SIZE);
if (NULL == cmdBuffer) {
errorPrint("%s", "failed to allocate memory\n");
goto end_insert_process; goto end_insert_process;
} }
printfInsertMeta();
debugPrint("%d result file: %s\n", __LINE__, g_Dbs.resultFile); debugPrint("%d result file: %s\n", __LINE__, g_Dbs.resultFile);
g_fpOfInsertResult = fopen(g_Dbs.resultFile, "a"); g_fpOfInsertResult = fopen(g_Dbs.resultFile, "a");
if (NULL == g_fpOfInsertResult) { if (NULL == g_fpOfInsertResult) {
...@@ -4564,11 +4567,7 @@ int insertTestProcess() { ...@@ -4564,11 +4567,7 @@ int insertTestProcess() {
} }
// create database and super tables // create database and super tables
char *cmdBuffer = calloc(1, BUFFER_SIZE);
if (NULL == cmdBuffer) {
errorPrint("%s", "failed to allocate memory\n");
goto end_insert_process;
}
if (createDatabasesAndStables(cmdBuffer)) { if (createDatabasesAndStables(cmdBuffer)) {
goto end_insert_process; goto end_insert_process;
} }
......
...@@ -375,7 +375,7 @@ for any corresponding short options.\n\ ...@@ -375,7 +375,7 @@ for any corresponding short options.\n\
Report bugs to <support@taosdata.com>.\n"); Report bugs to <support@taosdata.com>.\n");
} }
int printfInsertMeta() { void printfInsertMeta() {
setupForAnsiEscape(); setupForAnsiEscape();
SHOW_PARSE_RESULT_START(); SHOW_PARSE_RESULT_START();
...@@ -481,7 +481,6 @@ int printfInsertMeta() { ...@@ -481,7 +481,6 @@ int printfInsertMeta() {
} else { } else {
printf("\033[1m\033[40;31m precision error: %s\033[0m\n", printf("\033[1m\033[40;31m precision error: %s\033[0m\n",
g_Dbs.db[i].dbCfg.precision); g_Dbs.db[i].dbCfg.precision);
return -1;
} }
} }
...@@ -635,7 +634,6 @@ int printfInsertMeta() { ...@@ -635,7 +634,6 @@ int printfInsertMeta() {
SHOW_PARSE_RESULT_END(); SHOW_PARSE_RESULT_END();
resetAfterAnsiEscape(); resetAfterAnsiEscape();
return 0;
} }
void printfInsertMetaToFile(FILE *fp) { void printfInsertMetaToFile(FILE *fp) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册