From fcbb395dc7ff3edab972b6d4b27dbbfb3305f5d7 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 26 Dec 2021 15:58:40 +0300 Subject: PBYTE -> uint8_t* --- plugins/BasicHistory/src/DatExport.cpp | 2 +- plugins/BasicHistory/src/EventList.cpp | 4 ++-- plugins/BasicHistory/src/Scheduler.cpp | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) (limited to 'plugins/BasicHistory/src') diff --git a/plugins/BasicHistory/src/DatExport.cpp b/plugins/BasicHistory/src/DatExport.cpp index c6a020fb05..3b1fa0f8cb 100644 --- a/plugins/BasicHistory/src/DatExport.cpp +++ b/plugins/BasicHistory/src/DatExport.cpp @@ -181,7 +181,7 @@ bool DatExport::GetEventList(std::vector& eventList) info.flags = messageHeader.flags; info.timestamp = messageHeader.timestamp; info.cbBlob = messageHeader.cbBlob; - info.pBlob = (PBYTE)memBuf.c_str(); + info.pBlob = (uint8_t*)memBuf.c_str(); HistoryEventList::GetObjectDescription(&info, _str, MAXSELECTSTR); exMsg.message = _str; sortedEvents.insert(std::pair(messageHeader.timestamp, exMsg)); diff --git a/plugins/BasicHistory/src/EventList.cpp b/plugins/BasicHistory/src/EventList.cpp index b686dbc998..39ff4ff4ca 100644 --- a/plugins/BasicHistory/src/EventList.cpp +++ b/plugins/BasicHistory/src/EventList.cpp @@ -508,7 +508,7 @@ void HistoryEventList::MargeMessages(const std::vector dbei.cbBlob = WideCharToMultiByte(cp, 0, msg.message.c_str(), (int)msg.message.length() + 1, nullptr, 0, nullptr, nullptr); char* buf = new char[dbei.cbBlob]; dbei.cbBlob = WideCharToMultiByte(cp, 0, msg.message.c_str(), (int)msg.message.length() + 1, buf, dbei.cbBlob, nullptr, nullptr); - dbei.pBlob = (PBYTE)buf; + dbei.pBlob = (uint8_t*)buf; db_event_add(m_hContact, &dbei); delete[] buf; } @@ -524,7 +524,7 @@ bool HistoryEventList::GetEventData(const EventIndex& ev, EventData& data) if (!ev.isExternal) { DWORD newBlobSize = db_event_getBlobSize(ev.hEvent); if (newBlobSize > m_oldBlobSize) { - m_dbei.pBlob = (PBYTE)mir_realloc(m_dbei.pBlob, newBlobSize); + m_dbei.pBlob = (uint8_t*)mir_realloc(m_dbei.pBlob, newBlobSize); m_oldBlobSize = newBlobSize; } diff --git a/plugins/BasicHistory/src/Scheduler.cpp b/plugins/BasicHistory/src/Scheduler.cpp index 51cce458ec..ad53e27731 100644 --- a/plugins/BasicHistory/src/Scheduler.cpp +++ b/plugins/BasicHistory/src/Scheduler.cpp @@ -1285,7 +1285,7 @@ void DoError(const TaskOptions& to, const std::wstring _error) dbei.cbBlob = WideCharToMultiByte(CP_UTF8, 0, error.c_str(), len, nullptr, 0, nullptr, nullptr); char* buf = new char[dbei.cbBlob]; dbei.cbBlob = WideCharToMultiByte(CP_UTF8, 0, error.c_str(), len, buf, dbei.cbBlob, nullptr, nullptr); - dbei.pBlob = (PBYTE)buf; + dbei.pBlob = (uint8_t*)buf; db_event_add(NULL, &dbei); } -- cgit v1.2.3