summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--protocols/Tox/src/tox_proto.h2
-rw-r--r--protocols/Tox/src/tox_utils.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/protocols/Tox/src/tox_proto.h b/protocols/Tox/src/tox_proto.h
index 65f465d485..c815815fd7 100644
--- a/protocols/Tox/src/tox_proto.h
+++ b/protocols/Tox/src/tox_proto.h
@@ -277,7 +277,7 @@ private:
static bool IsFileExists(std::tstring path);
- MEVENT AddEventToDb(MCONTACT hContact, WORD type, DWORD timestamp, DWORD flags, PBYTE pBlob, DWORD cbBlob);
+ MEVENT AddEventToDb(MCONTACT hContact, WORD type, DWORD timestamp, DWORD flags, PBYTE pBlob, size_t cbBlob);
template<INT_PTR(__cdecl CToxProto::*Service)(WPARAM, LPARAM)>
static INT_PTR __cdecl GlobalService(WPARAM wParam, LPARAM lParam)
diff --git a/protocols/Tox/src/tox_utils.cpp b/protocols/Tox/src/tox_utils.cpp
index 988f2a24f3..2b22f02849 100644
--- a/protocols/Tox/src/tox_utils.cpp
+++ b/protocols/Tox/src/tox_utils.cpp
@@ -65,13 +65,13 @@ bool CToxProto::IsFileExists(std::tstring path)
return _taccess(path.c_str(), 0) == 0;
}
-MEVENT CToxProto::AddEventToDb(MCONTACT hContact, WORD type, DWORD timestamp, DWORD flags, PBYTE pBlob, DWORD cbBlob)
+MEVENT CToxProto::AddEventToDb(MCONTACT hContact, WORD type, DWORD timestamp, DWORD flags, PBYTE pBlob, size_t cbBlob)
{
DBEVENTINFO dbei = { sizeof(dbei) };
dbei.szModule = this->m_szModuleName;
dbei.timestamp = timestamp;
dbei.eventType = type;
- dbei.cbBlob = cbBlob;
+ dbei.cbBlob = (DWORD)cbBlob;
dbei.pBlob = pBlob;
dbei.flags = flags;
return db_event_add(hContact, &dbei);