[TD-13756]<fix>: log file open fail error.
This commit is contained in:
parent
e9f2c1cdc0
commit
131bf46854
|
@ -353,7 +353,9 @@ static int32_t taosOpenLogFile(char *fn, int32_t maxLines, int32_t maxFileNum) {
|
|||
printf("\nfailed to open log file:%s, reason:%s\n", fileName, strerror(errno));
|
||||
return -1;
|
||||
}
|
||||
taosCloseFile(&tsLogObj.logHandle->pFile);
|
||||
TdFilePtr pOldFile = tsLogObj.logHandle->pFile;
|
||||
taosUnLockLogFile(pOldFile);
|
||||
taosCloseFile(&pOldFile);
|
||||
tsLogObj.logHandle->pFile = pFile;
|
||||
taosLockLogFile(tsLogObj.logHandle->pFile);
|
||||
|
||||
|
|
Loading…
Reference in New Issue