diff options
author | George Hazan <ghazan@miranda.im> | 2017-11-23 22:06:26 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2017-11-23 22:06:26 +0300 |
commit | 6d6cb956a78b2dbfa7e8d62f4234d8f27b100468 (patch) | |
tree | e41f29a86d93ffc0ca414e8d84c8cdd47847baeb /protocols | |
parent | 6bb0abf1e62b18e4029ae0b7b73ee47f3fe3b39d (diff) |
database enumerators => void* instead of LPARAM
Diffstat (limited to 'protocols')
-rw-r--r-- | protocols/IRCG/src/ircproto.cpp | 2 | ||||
-rw-r--r-- | protocols/IRCG/src/options.cpp | 2 | ||||
-rw-r--r-- | protocols/IcqOscarJ/src/icq_servlist.cpp | 6 | ||||
-rw-r--r-- | protocols/IcqOscarJ/src/icq_uploadui.cpp | 2 | ||||
-rwxr-xr-x | protocols/JabberG/src/jabber_omemo.cpp | 10 |
5 files changed, 11 insertions, 11 deletions
diff --git a/protocols/IRCG/src/ircproto.cpp b/protocols/IRCG/src/ircproto.cpp index 5ce755d6cb..869732806a 100644 --- a/protocols/IRCG/src/ircproto.cpp +++ b/protocols/IRCG/src/ircproto.cpp @@ -156,7 +156,7 @@ CIrcProto::~CIrcProto() ////////////////////////////////////////////////////////////////////////////////////////
// OnModulesLoaded - performs hook registration
-static int sttCheckPerform(const char *szSetting, LPARAM lParam)
+static int sttCheckPerform(const char *szSetting, void *lParam)
{
if (!_strnicmp(szSetting, "PERFORM:", 8)) {
CMStringA s = szSetting;
diff --git a/protocols/IRCG/src/options.cpp b/protocols/IRCG/src/options.cpp index 1d93bf88bb..374500cb5f 100644 --- a/protocols/IRCG/src/options.cpp +++ b/protocols/IRCG/src/options.cpp @@ -110,7 +110,7 @@ void CIrcProto::WriteSettings( TDbSetting* sets, int count ) /////////////////////////////////////////////////////////////////////////////////////////
-static int sttServerEnum( const char* szSetting, LPARAM )
+static int sttServerEnum( const char* szSetting, void*)
{
DBVARIANT dbv;
if (db_get_s(NULL, SERVERSMODULE, szSetting, &dbv))
diff --git a/protocols/IcqOscarJ/src/icq_servlist.cpp b/protocols/IcqOscarJ/src/icq_servlist.cpp index 11291eb889..4a562bf016 100644 --- a/protocols/IcqOscarJ/src/icq_servlist.cpp +++ b/protocols/IcqOscarJ/src/icq_servlist.cpp @@ -812,7 +812,7 @@ struct GroupReserveIdsEnumParam char *szModule;
};
-static int GroupReserveIdsEnumProc(const char *szSetting, LPARAM lParam)
+static int GroupReserveIdsEnumProc(const char *szSetting, void *lParam)
{
if (szSetting && mir_strlen(szSetting) < 5) {
// it is probably server group
@@ -1252,7 +1252,7 @@ void* CIcqProto::collectGroups(int *count) return buf;
}
-static int GroupLinksEnumProc(const char *szSetting, LPARAM lParam)
+static int GroupLinksEnumProc(const char *szSetting, void *lParam)
{
// check link target, add if match
if (db_get_w(NULL, ((char**)lParam)[2], szSetting, 0) == (WORD)((char**)lParam)[1]) {
@@ -1489,7 +1489,7 @@ char *CIcqProto::getServListGroupCListPath(WORD wGroupId) }
-static int SrvGroupNamesEnumProc(const char *szSetting, LPARAM lParam)
+static int SrvGroupNamesEnumProc(const char *szSetting, void *lParam)
{
// check server-group cache item
const char **params = (const char**)lParam;
diff --git a/protocols/IcqOscarJ/src/icq_uploadui.cpp b/protocols/IcqOscarJ/src/icq_uploadui.cpp index afa1843853..139f89a658 100644 --- a/protocols/IcqOscarJ/src/icq_uploadui.cpp +++ b/protocols/IcqOscarJ/src/icq_uploadui.cpp @@ -131,7 +131,7 @@ static void GetLastUploadLogLine(HWND hwndDlg, char *szBuf, size_t cbBuf) make_utf8_string_static(str, szBuf, cbBuf);
}
-static int GroupEnumIdsEnumProc(const char *szSetting, LPARAM lParam)
+static int GroupEnumIdsEnumProc(const char *szSetting, void *lParam)
{
// it is probably server group
if (szSetting && mir_strlen(szSetting) < 5) {
diff --git a/protocols/JabberG/src/jabber_omemo.cpp b/protocols/JabberG/src/jabber_omemo.cpp index d06af0543d..48512b0da9 100755 --- a/protocols/JabberG/src/jabber_omemo.cpp +++ b/protocols/JabberG/src/jabber_omemo.cpp @@ -722,7 +722,7 @@ namespace omemo { db_enum_settings_sub_cb_data(); //we always need array size
};
- int db_enum_settings_sub_cb(const char *szSetting, LPARAM lParam)
+ int db_enum_settings_sub_cb(const char *szSetting, void *lParam)
{
db_enum_settings_sub_cb_data* data = (db_enum_settings_sub_cb_data*)lParam;
if (strstr(szSetting, "OmemoSignalSession_"))
@@ -765,7 +765,7 @@ namespace omemo { ud->sessions = l;
ud->name = name;
ud->name_len = name_len;
- db_enum_settings(data->hContact, &db_enum_settings_sub_cb, data->proto->m_szModuleName, (void*)ud);
+ db_enum_settings(data->hContact, &db_enum_settings_sub_cb, data->proto->m_szModuleName, ud);
*sessions = l;
delete ud;
return array_size;
@@ -870,7 +870,7 @@ namespace omemo { size_t name_len;
};
- int db_enum_settings_del_all_cb(const char *szSetting, LPARAM lParam)
+ int db_enum_settings_del_all_cb(const char *szSetting, void *lParam)
{
db_enum_settings_del_all_cb_data* data = (db_enum_settings_del_all_cb_data*)lParam;
if (strstr(szSetting, "OmemoSignalSession_"))
@@ -1989,7 +1989,7 @@ struct db_enum_settings_prekeys_cb_data };
-int db_enum_settings_prekeys_cb(const char *szSetting, LPARAM lParam)
+int db_enum_settings_prekeys_cb(const char *szSetting, void *lParam)
{
db_enum_settings_prekeys_cb_data* data = (db_enum_settings_prekeys_cb_data*)lParam;
if (strstr(szSetting, "OmemoPreKey") && strstr(szSetting, "Public")) //TODO: suboptimal code, use different names for simple searching
@@ -2031,7 +2031,7 @@ void CJabberProto::OmemoSendBundle() HXML prekeys_node = XmlAddChild(bundle_node, L"prekeys");
db_enum_settings_prekeys_cb_data *ud = new db_enum_settings_prekeys_cb_data;
- db_enum_settings(0, &db_enum_settings_prekeys_cb, m_szModuleName, (void*)ud);
+ db_enum_settings(0, &db_enum_settings_prekeys_cb, m_szModuleName, ud);
for (std::list<char*>::iterator i = ud->settings.begin(), end = ud->settings.end(); i != end; i++)
{
ptrW val(getWStringA(*i));
|