diff options
author | George Hazan <ghazan@miranda.im> | 2018-04-27 11:09:35 +0200 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-04-27 11:09:35 +0200 |
commit | 37071053f2bfb38733d0ef912b3a414f67b8be03 (patch) | |
tree | 42262aae263f7641cdf29532ca36433be6f87965 /plugins | |
parent | 514228ea703402929e9a155517688660acf046a3 (diff) |
Boltun: fix for storing events into the database
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/Boltun/src/actionQueue.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/plugins/Boltun/src/actionQueue.cpp b/plugins/Boltun/src/actionQueue.cpp index ea9b89d215..fbad765f55 100644 --- a/plugins/Boltun/src/actionQueue.cpp +++ b/plugins/Boltun/src/actionQueue.cpp @@ -84,15 +84,13 @@ static bool NotifyTyping(MCONTACT hContact) static void TimerAnswer(MCONTACT hContact, const TalkBot::MessageInfo* info)
{
T2Utf msg(info->Answer.c_str());
- size_t bufsize = mir_strlen(msg);
-
ProtoChainSend(hContact, PSS_MESSAGE, 0, (LPARAM)msg);
DBEVENTINFO dbei = {};
- dbei.cbBlob = (int)bufsize;
- dbei.pBlob = (PBYTE)(char*)msg;
+ dbei.cbBlob = (int)mir_strlen(msg);
+ dbei.pBlob = msg;
dbei.eventType = EVENTTYPE_MESSAGE;
- dbei.flags = DBEF_SENT;
+ dbei.flags = DBEF_SENT | DBEF_UTF;
dbei.szModule = BOLTUN_NAME;
dbei.timestamp = (DWORD)time(nullptr);
|