Skip to content

Commit

Permalink
Merge pull request #748 from taosdata/feat/TD-30413
Browse files Browse the repository at this point in the history
fix: csv file check null pointer
  • Loading branch information
DuanKuanJun committed Jun 5, 2024
2 parents b6a13a1 + 1fd9f66 commit 8e564e4
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/benchData.c
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,10 @@ static int generateSampleFromCsv(char *buffer, char* file, FILE* fp, int32_t len

if (file != NULL && fp == NULL) {
fp = fopen(file, "r");
if (fp == NULL) {
errorPrint("open csv file failed. file=%s\n", file);
return -1;
}
needClose = true;
}

Expand Down

0 comments on commit 8e564e4

Please sign in to comment.