[TD-5534]<fix>:fix the coverity high risk of client

This commit is contained in:
markswang 2021-07-27 17:08:32 +08:00
parent 3e96e64521
commit b2c0fbe0ce
1 changed files with 1 additions and 1 deletions

View File

@ -964,7 +964,7 @@ JNIEXPORT jlong JNICALL Java_com_taosdata_jdbc_TSDBJNIConnector_insertLinesImp(J
int numLines = (*env)->GetArrayLength(env, lines); int numLines = (*env)->GetArrayLength(env, lines);
char** c_lines = calloc(numLines, sizeof(char*)); char** c_lines = calloc(numLines, sizeof(char*));
if (c_lines == NULL) { if (c_lines == NULL) {
jniError("c_lines:%d, alloc memory failed", c_lines); jniError("c_lines:%p, alloc memory failed", c_lines);
return JNI_OUT_OF_MEMORY; return JNI_OUT_OF_MEMORY;
} }
for (int i = 0; i < numLines; ++i) { for (int i = 0; i < numLines; ++i) {