summaryrefslogtreecommitdiff
path: root/plugins/YARelay/src
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/YARelay/src')
-rw-r--r--plugins/YARelay/src/main.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/plugins/YARelay/src/main.cpp b/plugins/YARelay/src/main.cpp
index 4a29fedc9f..5abc1cbc44 100644
--- a/plugins/YARelay/src/main.cpp
+++ b/plugins/YARelay/src/main.cpp
@@ -113,12 +113,8 @@ static int MessageEventAdded(WPARAM hContact, LPARAM hDBEvent)
return 0;
// receive message from DB
- DBEVENTINFO dbei = {};
- dbei.cbBlob = db_event_getBlobSize(hDBEvent);
- if (dbei.cbBlob == -1)
- return 0;
-
- dbei.pBlob = (unsigned char*)alloca(dbei.cbBlob);
+ DB::EventInfo dbei;
+ dbei.cbBlob = -1;
db_event_get(hDBEvent, &dbei);
if (dbei.flags & DBEF_SENT || dbei.flags & DBEF_READ || (dbei.eventType != EVENTTYPE_MESSAGE))
return 0;