summaryrefslogtreecommitdiff
path: root/plugins/NotesAndReminders/src/miscutils.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2013-06-30 12:16:44 +0000
committerGeorge Hazan <george.hazan@gmail.com>2013-06-30 12:16:44 +0000
commit25ec54ea27a7099f33573b260a620ed7273176fe (patch)
tree1810a0cb35d23deeed9ccdaf0ab276a4022f9a41 /plugins/NotesAndReminders/src/miscutils.cpp
parenta546606709e6bb72e01eb38b2c8c8756608fd5d6 (diff)
- db_set_blob used everywhere for writing blobs
- DBCONTACTWRITESETTING left only in the event handlers git-svn-id: http://svn.miranda-ng.org/main/trunk@5191 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/NotesAndReminders/src/miscutils.cpp')
-rw-r--r--plugins/NotesAndReminders/src/miscutils.cpp15
1 files changed, 1 insertions, 14 deletions
diff --git a/plugins/NotesAndReminders/src/miscutils.cpp b/plugins/NotesAndReminders/src/miscutils.cpp
index 3031922af6..f29ef4c233 100644
--- a/plugins/NotesAndReminders/src/miscutils.cpp
+++ b/plugins/NotesAndReminders/src/miscutils.cpp
@@ -32,19 +32,6 @@ void FreeSettingBlob(WORD pSize,void *pbBlob)
db_free(&dbv);
}
-void WriteSettingBlob(HANDLE hContact,char *ModuleName,char *SettingName,WORD pSize,void *pbBlob)
-{
- DBCONTACTWRITESETTING cgs = {0};
- DBVARIANT dbv = {0};
- dbv.type = DBVT_BLOB;
- dbv.cpbVal = pSize;
- dbv.pbVal = (BYTE*)pbBlob;
- cgs.szModule = ModuleName;
- cgs.szSetting = SettingName;
- cgs.value = dbv;
- CallService(MS_DB_CONTACT_WRITESETTING,(DWORD)hContact,(DWORD)&cgs);
-}
-
void ReadSettingBlob(HANDLE hContact, char *ModuleName, char *SettingName, WORD *pSize, void **pbBlob)
{
DBVARIANT dbv = {0};
@@ -61,7 +48,7 @@ void ReadSettingBlob(HANDLE hContact, char *ModuleName, char *SettingName, WORD
void WriteSettingIntArray(HANDLE hContact,char *ModuleName,char *SettingName,const int *Value, int Size)
{
- WriteSettingBlob(hContact, ModuleName, SettingName, WORD(sizeof(int)*Size), (void*)Value);
+ db_set_blob(hContact, ModuleName, SettingName, (void*)Value, sizeof(int)*Size);
}
bool ReadSettingIntArray(HANDLE hContact,char *ModuleName,char *SettingName,int *Value, int Size)