8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-23 02:03:04 +01:00

More corrections according to Adriano review

This commit is contained in:
Vlad Khorsun 2022-06-03 11:22:57 +03:00
parent f881f3119c
commit e5badeb332
3 changed files with 5 additions and 6 deletions

View File

@ -42,7 +42,7 @@ namespace Burp
IOBuffer::IOBuffer(void* item, FB_SIZE_T size) :
m_item(item),
m_memory(NULL),
m_memory(*getDefaultMemoryPool(), size),
m_aligned(NULL),
m_size(size),
m_used(0),
@ -52,8 +52,7 @@ IOBuffer::IOBuffer(void* item, FB_SIZE_T size) :
m_locked(0)
{
m_memory = new UCHAR[m_size];
m_aligned = m_memory;
m_aligned = m_memory.getBuffer(m_size);
}

View File

@ -561,7 +561,7 @@ public:
private:
void* const m_item;
Firebird::AutoPtr<UCHAR> m_memory;
Firebird::Array<UCHAR> m_memory;
UCHAR* m_aligned;
const FB_SIZE_T m_size;
FB_SIZE_T m_used;

View File

@ -39,9 +39,9 @@ THREAD_ENTRY_DECLARE WorkerThread::workerThreadRoutine(THREAD_ENTRY_PARAM arg)
WorkerThread* WorkerThread::start(Coordinator* coordinator)
{
AutoPtr<WorkerThread> thd = new WorkerThread(coordinator);
AutoPtr<WorkerThread> thd = FB_NEW WorkerThread(coordinator);
Thread::start(WorkerThread::workerThreadRoutine, thd, THREAD_medium, &thd->m_thdHandle);
Thread::start(workerThreadRoutine, thd, THREAD_medium, &thd->m_thdHandle);
return thd.release();
}