summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-11-29 11:42:53 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-11-29 11:42:53 +0000
commit35d3ce335858b8ac7c9db915f798f2f6a916a16d (patch)
treea44f9ddcb16a0ea373e1ad8259dea4bb64771115
parentd0548b5d631f44cad9bbce5ac521717c87cef3ad (diff)
missing macros
git-svn-id: http://svn.miranda-ng.org/main/trunk@2556 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
-rw-r--r--include/m_core.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/include/m_core.h b/include/m_core.h
index 33473dda71..5b91dbe550 100644
--- a/include/m_core.h
+++ b/include/m_core.h
@@ -99,7 +99,7 @@ MIR_CORE_DLL(int) db_get_b(HANDLE hContact, const char *szModule, const char
MIR_CORE_DLL(int) db_get_w(HANDLE hContact, const char *szModule, const char *szSetting, int errorValue);
MIR_CORE_DLL(DWORD) db_get_dw(HANDLE hContact, const char *szModule, const char *szSetting, DWORD errorValue);
MIR_CORE_DLL(INT_PTR) db_get(HANDLE hContact, const char *szModule, const char *szSetting, DBVARIANT *dbv);
-MIR_CORE_DLL(INT_PTR) db_get_s(HANDLE hContact, const char *szModule, const char *szSetting, DBVARIANT *dbv, const int nType);
+MIR_CORE_DLL(INT_PTR) db_get_s(HANDLE hContact, const char *szModule, const char *szSetting, DBVARIANT *dbv, const int nType=DBVT_ASCIIZ);
MIR_CORE_DLL(char*) db_get_sa(HANDLE hContact, const char *szModule, const char *szSetting);
MIR_CORE_DLL(WCHAR*) db_get_wsa(HANDLE hContact, const char *szModule, const char *szSetting);
@@ -111,10 +111,15 @@ MIR_CORE_DLL(INT_PTR) db_set_ws(HANDLE hContact, const char *szModule, const cha
MIR_CORE_DLL(INT_PTR) db_set_utf(HANDLE hContact, const char *szModule, const char *szSetting, const char *val);
MIR_CORE_DLL(INT_PTR) db_set_blob(HANDLE hContact, const char *szModule, const char *szSetting, void *val, unsigned len);
+#define db_get_ws(a,b,c,d) db_get_s(a,b,c,d,DBVT_WCHAR)
+#define db_get_utf(a,b,c,d) db_get_s(a,b,c,d,DBVT_UTF8)
+
#ifdef _UNICODE
+ #define db_get_ts(a,b,c,d) db_get_s(a,b,c,d,DBVT_WCHAR)
#define db_get_tsa db_get_wsa
#define db_set_ts db_set_ws
#else
+ #define db_get_ts(a,b,c,d) db_get_s(a,b,c,d,DBVT_ASCIIZ)
#define db_get_tsa db_get_sa
#define db_set_ts db_set_s
#endif