summaryrefslogtreecommitdiff
path: root/protocols/AimOscar/src
diff options
context:
space:
mode:
authorKirill Volinsky <mataes2007@gmail.com>2015-05-22 12:33:13 +0000
committerKirill Volinsky <mataes2007@gmail.com>2015-05-22 12:33:13 +0000
commit159b565b390687258ee65a3b66596e118752063c (patch)
tree91105378fcb9e030ba4a7f6572c4ea307cb8c8d6 /protocols/AimOscar/src
parent7f4d529b59698d7eb2403bd1f9088a5aa7fa9080 (diff)
replace strcmp to mir_strcmp
git-svn-id: http://svn.miranda-ng.org/main/trunk@13752 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/AimOscar/src')
-rw-r--r--protocols/AimOscar/src/chat.cpp6
-rw-r--r--protocols/AimOscar/src/server.cpp10
-rw-r--r--protocols/AimOscar/src/services.cpp6
-rw-r--r--protocols/AimOscar/src/theme.cpp2
-rw-r--r--protocols/AimOscar/src/ui.cpp8
-rw-r--r--protocols/AimOscar/src/utility.cpp12
6 files changed, 22 insertions, 22 deletions
diff --git a/protocols/AimOscar/src/chat.cpp b/protocols/AimOscar/src/chat.cpp
index 73b8a61b91..a861dccb84 100644
--- a/protocols/AimOscar/src/chat.cpp
+++ b/protocols/AimOscar/src/chat.cpp
@@ -107,7 +107,7 @@ int CAimProto::OnGCEvent(WPARAM, LPARAM lParam)
GCHOOK *gch = (GCHOOK*) lParam;
if (!gch) return 1;
- if (strcmp(gch->pDest->pszModule, m_szModuleName)) return 0;
+ if (mir_strcmp(gch->pDest->pszModule, m_szModuleName)) return 0;
char* id = mir_t2a(gch->pDest->ptszID);
chat_list_item* item = find_chat_by_id(id);
@@ -206,7 +206,7 @@ int CAimProto::OnGCMenuHook(WPARAM, LPARAM lParam)
else if ( gcmi->Type == MENU_ON_NICKLIST )
{
char* sn = mir_t2a(gcmi->pszUID);
- if ( !strcmp(username, sn))
+ if ( !mir_strcmp(username, sn))
{
static const struct gc_item Items[] = {
{ TranslateT("User &details"), 10, MENU_ITEM, FALSE },
@@ -265,7 +265,7 @@ chat_list_item* CAimProto::find_chat_by_id(char* id)
chat_list_item* item = NULL;
for(int i=0; i<chat_rooms.getCount(); ++i)
{
- if (strcmp(chat_rooms[i].id, id) == 0)
+ if (mir_strcmp(chat_rooms[i].id, id) == 0)
{
item = &chat_rooms[i];
break;
diff --git a/protocols/AimOscar/src/server.cpp b/protocols/AimOscar/src/server.cpp
index 3ae332dc39..1f3a2403d9 100644
--- a/protocols/AimOscar/src/server.cpp
+++ b/protocols/AimOscar/src/server.cpp
@@ -659,13 +659,13 @@ void CAimProto::process_ssi_list(SNAC &snac, int &offset)
bool ok = false;
DBVARIANT dbv;
if (!db_get_utf(hContact, MOD_KEY_CL, OTH_KEY_GP, &dbv) && dbv.pszVal[0]) {
- ok = strcmp(group, dbv.pszVal) == 0;
+ ok = mir_strcmp(group, dbv.pszVal) == 0;
db_free(&dbv);
}
- else ok = strcmp(group, AIM_DEFAULT_GROUP) == 0;
+ else ok = mir_strcmp(group, AIM_DEFAULT_GROUP) == 0;
if (!ok) {
- if (strcmp(group, AIM_DEFAULT_GROUP))
+ if (mir_strcmp(group, AIM_DEFAULT_GROUP))
db_set_utf(hContact, MOD_KEY_CL, OTH_KEY_GP, group);
else
db_unset(hContact, MOD_KEY_CL, OTH_KEY_GP);
@@ -1181,7 +1181,7 @@ void CAimProto::snac_received_message(SNAC &snac,HANDLE hServerConn,unsigned sho
}
else if (tlv.cmp(0x2712)) {
char* enc = tlv.dup();
- utf_fname = strcmp(enc, "utf-8") == 0;
+ utf_fname = mir_strcmp(enc, "utf-8") == 0;
mir_free(enc);
}
else if (tlv.cmp(0x2713)) {
@@ -1204,7 +1204,7 @@ void CAimProto::snac_received_message(SNAC &snac,HANDLE hServerConn,unsigned sho
}
else if (tlv.cmp(0x000d)) {
char* enc = tlv.dup();
- unicode_descr = strcmp(enc, "unicode-2-0") == 0;
+ unicode_descr = mir_strcmp(enc, "unicode-2-0") == 0;
mir_free(enc);
}
i += TLV_HEADER_SIZE + tlv.len();
diff --git a/protocols/AimOscar/src/services.cpp b/protocols/AimOscar/src/services.cpp
index 886e001ef3..5097b0d080 100644
--- a/protocols/AimOscar/src/services.cpp
+++ b/protocols/AimOscar/src/services.cpp
@@ -117,9 +117,9 @@ int CAimProto::OnDbSettingChanged(WPARAM hContact, LPARAM lParam)
{
DBCONTACTWRITESETTING *cws = (DBCONTACTWRITESETTING*)lParam;
- if (strcmp(cws->szModule, MOD_KEY_CL) == 0 && state == 1 && hContact)
+ if (mir_strcmp(cws->szModule, MOD_KEY_CL) == 0 && state == 1 && hContact)
{
- if (strcmp(cws->szSetting, AIM_KEY_NL) == 0)
+ if (mir_strcmp(cws->szSetting, AIM_KEY_NL) == 0)
{
if (cws->value.type == DBVT_DELETED)
{
@@ -133,7 +133,7 @@ int CAimProto::OnDbSettingChanged(WPARAM hContact, LPARAM lParam)
add_contact_to_group(hContact, AIM_DEFAULT_GROUP);
}
}
- else if (strcmp(cws->szSetting, "MyHandle") == 0)
+ else if (mir_strcmp(cws->szSetting, "MyHandle") == 0)
{
char* name;
switch (cws->value.type)
diff --git a/protocols/AimOscar/src/theme.cpp b/protocols/AimOscar/src/theme.cpp
index 36acbcef17..b9449f78fb 100644
--- a/protocols/AimOscar/src/theme.cpp
+++ b/protocols/AimOscar/src/theme.cpp
@@ -70,7 +70,7 @@ HICON LoadIconEx(const char* name, bool big)
HANDLE GetIconHandle(const char* name)
{
for (int i=0; i < SIZEOF(iconList); i++)
- if ( !strcmp(iconList[i].szName, name))
+ if ( !mir_strcmp(iconList[i].szName, name))
return iconList[i].hIcolib;
return NULL;
diff --git a/protocols/AimOscar/src/ui.cpp b/protocols/AimOscar/src/ui.cpp
index a01c6e54d7..2d2ba33223 100644
--- a/protocols/AimOscar/src/ui.cpp
+++ b/protocols/AimOscar/src/ui.cpp
@@ -694,7 +694,7 @@ INT_PTR CALLBACK admin_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPar
GetDlgItemTextA(hwndDlg, IDC_FNAME, name, SIZEOF(name));
if (mir_strlen(trim_str(name)) > 0 && !ppro->getString(AIM_KEY_SN, &dbv))
{
- if (strcmp(name, dbv.pszVal))
+ if (mir_strcmp(name, dbv.pszVal))
ppro->aim_admin_format_name(ppro->hAdminConn,ppro->admin_seqno,name);
db_free(&dbv);
}
@@ -703,7 +703,7 @@ INT_PTR CALLBACK admin_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPar
GetDlgItemTextA(hwndDlg, IDC_CEMAIL, email, SIZEOF(email));
if (mir_strlen(trim_str(email)) > 1 && !ppro->getString(AIM_KEY_EM, &dbv)) // Must be greater than 1 or a SNAC error is thrown.
{
- if (strcmp(email, dbv.pszVal))
+ if (mir_strcmp(email, dbv.pszVal))
ppro->aim_admin_change_email(ppro->hAdminConn,ppro->admin_seqno,email);
db_free(&dbv);
}
@@ -719,7 +719,7 @@ INT_PTR CALLBACK admin_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPar
// AOL only requires that you send the current password and a (single) new password.
// Let's allow the client to type (two) new passwords incase they make a mistake so we
// can handle any input error locally.
- if (strcmp(npw1,npw2) == 0)
+ if (mir_strcmp(npw1,npw2) == 0)
{
ppro->aim_admin_change_password(ppro->hAdminConn,ppro->admin_seqno,cpw,npw1);
}
@@ -891,7 +891,7 @@ static INT_PTR CALLBACK options_dialog(HWND hwndDlg, UINT msg, WPARAM wParam, LP
//HN
GetDlgItemTextA(hwndDlg, IDC_HN, str, SIZEOF(str));
- if (str[0] != 0 && strcmp(str, AIM_DEFAULT_SERVER))
+ if (str[0] != 0 && mir_strcmp(str, AIM_DEFAULT_SERVER))
ppro->setString(AIM_KEY_HN, str);
else
ppro->delSetting(AIM_KEY_HN);
diff --git a/protocols/AimOscar/src/utility.cpp b/protocols/AimOscar/src/utility.cpp
index ea7dafe878..ce2fac297a 100644
--- a/protocols/AimOscar/src/utility.cpp
+++ b/protocols/AimOscar/src/utility.cpp
@@ -160,7 +160,7 @@ unsigned short CAimProto::get_default_port(void)
bool CAimProto::is_my_contact(MCONTACT hContact)
{
const char* szProto = GetContactProto(hContact);
- return szProto != NULL && strcmp(m_szModuleName, szProto) == 0;
+ return szProto != NULL && mir_strcmp(m_szModuleName, szProto) == 0;
}
MCONTACT CAimProto::find_chat_contact(const char* room)
@@ -168,7 +168,7 @@ MCONTACT CAimProto::find_chat_contact(const char* room)
for (MCONTACT hContact = db_find_first(m_szModuleName); hContact; hContact = db_find_next(hContact, m_szModuleName)) {
DBVARIANT dbv;
if (!getString(hContact, "ChatRoomID", &dbv)) {
- bool found = !strcmp(room, dbv.pszVal);
+ bool found = !mir_strcmp(room, dbv.pszVal);
db_free(&dbv);
if (found)
return hContact;
@@ -184,7 +184,7 @@ MCONTACT CAimProto::contact_from_sn(const char* sn, bool addIfNeeded, bool tempo
for (MCONTACT hContact = db_find_first(m_szModuleName); hContact; hContact = db_find_next(hContact, m_szModuleName)) {
DBVARIANT dbv;
if (!getString(hContact, AIM_KEY_SN, &dbv)) {
- bool found = !strcmp(norm_sn, dbv.pszVal);
+ bool found = !mir_strcmp(norm_sn, dbv.pszVal);
db_free(&dbv);
if (found)
return hContact;
@@ -239,7 +239,7 @@ void CAimProto::add_contact_to_group(MCONTACT hContact, const char* new_group)
unsigned short old_group_id = getGroupId(hContact, 1);
char* old_group = group_list.find_name(old_group_id);
- if (old_group && strcmp(new_group, old_group) == 0)
+ if (old_group && mir_strcmp(new_group, old_group) == 0)
return;
DBVARIANT dbv;
@@ -260,7 +260,7 @@ void CAimProto::add_contact_to_group(MCONTACT hContact, const char* new_group)
debugLogA("Contact %u not on list.", hContact);
setGroupId(hContact, 1, new_group_id);
- if (new_group && strcmp(new_group, AIM_DEFAULT_GROUP))
+ if (new_group && mir_strcmp(new_group, AIM_DEFAULT_GROUP))
db_set_utf(hContact, MOD_KEY_CL, OTH_KEY_GP, new_group);
else
db_unset(hContact, MOD_KEY_CL, OTH_KEY_GP);
@@ -364,7 +364,7 @@ char* trim_str(char* s)
void create_group(const char *group)
{
- if (strcmp(group, AIM_DEFAULT_GROUP) == 0) return;
+ if (mir_strcmp(group, AIM_DEFAULT_GROUP) == 0) return;
TCHAR* szGroupName = mir_utf8decodeT(group);
Clist_CreateGroup(0, szGroupName);