You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-12-24 14:20:59 +03:00
Fix a few cppcheck issues
Found the following: * Potential stack explosions with alloca() usage on potentially large strings * Memory leaks in WriteEngineServer * Stack usage out of scope in dataconvert * A typo in an 'if' statement in dataconvert
This commit is contained in:
@@ -133,7 +133,7 @@ int ColumnBuffer::writeToFile(int startOffset, int writeSize, bool fillUpWEmptie
|
||||
|
||||
if (nitems != 1)
|
||||
{
|
||||
delete newBuf;
|
||||
delete [] newBuf;
|
||||
return ERR_FILE_WRITE;
|
||||
}
|
||||
|
||||
@@ -141,7 +141,7 @@ int ColumnBuffer::writeToFile(int startOffset, int writeSize, bool fillUpWEmptie
|
||||
Stats::stopParseEvent(WE_STATS_WRITE_COL);
|
||||
#endif
|
||||
|
||||
delete newBuf;
|
||||
delete [] newBuf;
|
||||
return NO_ERROR;
|
||||
}
|
||||
|
||||
|
||||
@@ -411,6 +411,7 @@ int ColumnInfoCompressed::truncateDctnryStore(
|
||||
fLog->logMsg( oss.str(), rc, MSGLVL_ERROR );
|
||||
fTruncateDctnryFileOp.closeFile( dFile );
|
||||
|
||||
delete [] pointerHdr;
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user