summaryrefslogtreecommitdiff
path: root/plugins/DbEditorPP/src/exportimport.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-12-18 18:24:23 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-12-18 18:24:23 +0000
commit380664004b21439985f148faaec988b0f28dc489 (patch)
treec25a177a35e0f763d068ac37f7196cbd9cc6e155 /plugins/DbEditorPP/src/exportimport.cpp
parent4051b9c5d1ac642751983cc0da7f5f991bbea474 (diff)
- crash fix for Win64 builds;
- some unneeded Unicode stuff wiped out git-svn-id: http://svn.miranda-ng.org/main/trunk@2762 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/DbEditorPP/src/exportimport.cpp')
-rw-r--r--plugins/DbEditorPP/src/exportimport.cpp18
1 files changed, 6 insertions, 12 deletions
diff --git a/plugins/DbEditorPP/src/exportimport.cpp b/plugins/DbEditorPP/src/exportimport.cpp
index b4c1142e2c..5f8006e9ec 100644
--- a/plugins/DbEditorPP/src/exportimport.cpp
+++ b/plugins/DbEditorPP/src/exportimport.cpp
@@ -415,41 +415,35 @@ void importSettings(HANDLE hContact, char *importstring )
i = i + (int)strlen("CONTACT:");
len = (int)strlen(&importstring[i]);
- if (len > 10)
- {
+ if (len > 10) {
char uid[256]="",szUID[256]="",szProto[512]="";
char *p1,*p2;
p1 = strrchr(&importstring[i], '>*{');
p2 = strrchr(&importstring[i], '}*');
- if (p1 && p2 && p1+3 < p2 && p2-p1 < SIZEOF(szUID))
- {
+ if (p1 && p2 && p1+3 < p2 && p2-p1 < SIZEOF(szUID)) {
strncpy(szUID, p1+1, p2-p1-2);
p1 = strrchr(&importstring[i], ')*<');
p2 = strrchr(&importstring[i], '>*{');
- if (p1 && p2 && p1+3 < p2 && p2-p1 < SIZEOF(uid))
- {
+ if (p1 && p2 && p1+3 < p2 && p2-p1 < SIZEOF(uid)) {
strncpy(uid, p1+1, p2-p1-3);
p1 = strrchr(&importstring[i], ' *(');
p2 = strrchr(&importstring[i], ')*<');
- if (p1 && p2 && p1+3 < p2 && p2-p1 < SIZEOF(szProto))
- {
+ if (p1 && p2 && p1+3 < p2 && p2-p1 < SIZEOF(szProto)) {
char *protouid;
strncpy(szProto, p1+1, p2-p1-3);
protouid = (char*)CallProtoService(szProto,PS_GETCAPS,PFLAG_UNIQUEIDSETTING,0);
- if ((int)protouid!=CALLSERVICE_NOTFOUND)
- {
+ if ((INT_PTR)protouid != CALLSERVICE_NOTFOUND) {
if (!mir_strcmp(protouid, uid))
hContact = CheckNewContact(szProto, uid, szUID);
}
- else
- hContact = CheckNewContact(szProto, uid, szUID);
+ else hContact = CheckNewContact(szProto, uid, szUID);
}
}
}