1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-07-30 19:23:07 +03:00

compiler warnings

like

dbcon/joblist/batchprimitiveprocessor-jl.cpp:893:54: error: pointer used after ‘void operator delete [](void*, std::size_t)’ [-Werror=use-after-free]
  893 |           joinResults.reset(new vector<uint32_t>[8192]);
      |                                                      ^
This commit is contained in:
Sergei Golubchik
2023-05-25 11:36:43 +02:00
committed by Gagan Goel
parent 4c3274affb
commit f5822b5ed3
2 changed files with 4 additions and 2 deletions

View File

@ -890,7 +890,8 @@ void BatchPrimitiveProcessorJL::getRowGroupData(ByteStream& in, vector<RGData>*
if (joinResults.get() == NULL)
{
joinResults.reset(new vector<uint32_t>[8192]);
auto v = new vector<uint32_t>[8192];
joinResults.reset(v);
tJoiners[j]->setPMJoinResults(joinResults, threadID);
}

View File

@ -359,7 +359,8 @@ void DiskJoinStep::joinFcn()
Row l_largeRow;
Row l_joinFERow, l_outputRow, baseRow;
vector<vector<Row::Pointer> > joinMatches;
std::shared_ptr<Row[]> smallRowTemplates(new Row[1]);
auto new_row = new Row[1];
std::shared_ptr<Row[]> smallRowTemplates(new_row);
vector<std::shared_ptr<TupleJoiner>> joiners;
std::shared_ptr<std::shared_ptr<int[]>[]> colMappings, fergMappings;
boost::scoped_array<boost::scoped_array<uint8_t> > smallNullMem;