diff options
Diffstat (limited to 'plugins/StopSpamMod/src')
-rwxr-xr-x | plugins/StopSpamMod/src/stopspam.cpp | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/plugins/StopSpamMod/src/stopspam.cpp b/plugins/StopSpamMod/src/stopspam.cpp index b32afb3e90..f1e7ca9361 100755 --- a/plugins/StopSpamMod/src/stopspam.cpp +++ b/plugins/StopSpamMod/src/stopspam.cpp @@ -19,14 +19,11 @@ int OnDbEventAdded(WPARAM hContact, LPARAM hDbEvent) { - DBEVENTINFO dbei = {}; - dbei.cbBlob = db_event_getBlobSize(hDbEvent); - if (dbei.cbBlob == -1) + DB::EventInfo dbei; + dbei.cbBlob = -1; + if (db_event_get(hDbEvent, &dbei)) return 0; - dbei.pBlob = (BYTE*)alloca(dbei.cbBlob); - db_event_get(hDbEvent, &dbei); - // if event is in protocol that is not despammed if (!ProtoInList(dbei.szModule)) return 0; |