enh(stream): set path max length to 1024
This commit is contained in:
parent
d7c0c054aa
commit
aa9e935854
|
@ -114,12 +114,12 @@ SStreamState* streamStateOpen(char* path, SStreamTask* pTask, bool specPath, int
|
|||
return NULL;
|
||||
}
|
||||
|
||||
char statePath[300];
|
||||
char statePath[1024];
|
||||
if (!specPath) {
|
||||
sprintf(statePath, "%s/%d", path, pTask->taskId);
|
||||
} else {
|
||||
memset(statePath, 0, 300);
|
||||
tstrncpy(statePath, path, 300);
|
||||
memset(statePath, 0, 1024);
|
||||
tstrncpy(statePath, path, 1024);
|
||||
}
|
||||
if (tdbOpen(statePath, szPage, pages, &pState->db, 0) < 0) {
|
||||
goto _err;
|
||||
|
|
|
@ -319,7 +319,7 @@ int32_t walEndSnapshot(SWal *pWal) {
|
|||
SWalFileInfo *pInfo = taosArraySearch(pWal->fileInfoSet, &tmp, compareWalFileInfo, TD_LE);
|
||||
if (pInfo) {
|
||||
if (ver >= pInfo->lastVer) {
|
||||
pInfo--;
|
||||
pInfo++;
|
||||
}
|
||||
if (POINTER_DISTANCE(pInfo, pWal->fileInfoSet->pData) > 0) {
|
||||
wDebug("vgId:%d, begin remove from %" PRId64, pWal->cfg.vgId, pInfo->firstVer);
|
||||
|
|
Loading…
Reference in New Issue