mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-24 17:30:44 +02:00
Fix/tsan (#3617)
* fix(Foundation): tsan warnings fixes * fix(Thread_POSIX): tsan warnings fixes; add tsan.suppress * fix(Util): tsan fixes * fix(netSSL_OpenSSL): tsan fixes * fix(Data): tsan warnings fixes * feat(ci): add tsan job * feat(ci): add tsan job, another attempt * feat(ci): add tsan job, 3rd attempt * fix(Foundation): tsan warnings fixes * fix(Thread_POSIX): tsan warnings fixes; add tsan.suppress * fix(Util): tsan fixes * fix(netSSL_OpenSSL): tsan fixes * fix(Data): tsan warnings fixes * feat(ci): add tsan job * feat(ci): add tsan job, another attempt * feat(ci): add tsan job, 3rd attempt * fix(ResultMetadata): memory leak #3474 * feat(ci): disable ActiveDispatcher tests for tsan runs * feat(ci): try to fix tsan options file detection (again) * chore(TestLibrary: correct spelling * fix(ci): fix tsan run; add -y to apt; disable samples build for some jobs * fix(ci): add mysql ports * feat(ci): add VS asan * feat(double-conversion): Upgrade double-conversion to v3.2.0 #3624 * chore(asan): disable msvc asan build (dll not found) * chore(double-conversion): move NumericString.h before double-conversion includes to prevent min/max collision; reinstate lost loongarch64 * chore(JSON): sync pdjson with upstream * fix(Statement): Poco::Data::Statement becomes unusable after exception #2287
This commit is contained in:
committed by
GitHub
parent
17fec1b985
commit
ff879f5905
@@ -147,13 +147,13 @@ namespace MySQL {
|
||||
|
||||
ResultMetadata::~ResultMetadata()
|
||||
{
|
||||
for (std::vector<char*>::iterator it = _buffer.begin(); it != _buffer.end(); ++it)
|
||||
std::free(*it);
|
||||
freeMemory();
|
||||
}
|
||||
|
||||
|
||||
void ResultMetadata::reset()
|
||||
{
|
||||
freeMemory();
|
||||
_columns.resize(0);
|
||||
_row.resize(0);
|
||||
_buffer.resize(0);
|
||||
@@ -162,14 +162,20 @@ void ResultMetadata::reset()
|
||||
}
|
||||
|
||||
|
||||
void ResultMetadata::freeMemory()
|
||||
{
|
||||
for (std::vector<char*>::iterator it = _buffer.begin(); it != _buffer.end(); ++it)
|
||||
std::free(*it);
|
||||
}
|
||||
|
||||
|
||||
void ResultMetadata::init(MYSQL_STMT* stmt)
|
||||
{
|
||||
ResultMetadataHandle h(stmt);
|
||||
|
||||
if (!h)
|
||||
{
|
||||
// all right, it is normal
|
||||
// querys such an "INSERT INTO" just does not have result at all
|
||||
// some queries (eg. INSERT) don't have result
|
||||
reset();
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user