You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-07-30 19:23:07 +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:
@ -2011,7 +2011,7 @@ int64_t DataConvert::convertColumnTimestamp(
|
||||
unsigned int dataOrgLen,
|
||||
const std::string& timeZone )
|
||||
{
|
||||
|
||||
char tmbuf[64];
|
||||
std::string dataOrgTemp = dataOrg;
|
||||
if (dataOrgTemp.substr(0, 19) == "0000-00-00 00:00:00")
|
||||
{
|
||||
@ -2023,7 +2023,6 @@ int64_t DataConvert::convertColumnTimestamp(
|
||||
if (strcmp(dataOrg, "current_timestamp() ON UPDATE current_timestamp()") == 0)
|
||||
{
|
||||
struct timeval tv;
|
||||
char tmbuf[64];
|
||||
gettimeofday(&tv, 0);
|
||||
MySQLTime time;
|
||||
gmtSecToMySQLTime(tv.tv_sec, time, timeZone);
|
||||
|
Reference in New Issue
Block a user