From 78c0815c4118fe24ab78cce2dc48a6232dcd824a Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sat, 2 Jun 2012 20:55:18 +0000 Subject: - code cleaning git-svn-id: http://svn.miranda-ng.org/main/trunk@270 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/SecureIM/crypt_lists.cpp | 46 ++++++++++++++++++++-------------------- 1 file changed, 23 insertions(+), 23 deletions(-) (limited to 'plugins/SecureIM/crypt_lists.cpp') diff --git a/plugins/SecureIM/crypt_lists.cpp b/plugins/SecureIM/crypt_lists.cpp index 48fbad16a0..f71398e4b4 100644 --- a/plugins/SecureIM/crypt_lists.cpp +++ b/plugins/SecureIM/crypt_lists.cpp @@ -11,10 +11,10 @@ void loadSupportedProtocols() { int numberOfProtocols; PROTOCOLDESCRIPTOR **protos; LPSTR szNames = myDBGetString(0,szModuleName,"protos"); - if( szNames && strchr(szNames,':') == NULL ) { + if ( szNames && strchr(szNames,':') == NULL ) { LPSTR tmp = (LPSTR) mir_alloc(2048); int j=0; for(int i=0; szNames[i]; i++) { - if( szNames[i] == ';' ) { + if ( szNames[i] == ';' ) { memcpy((PVOID)(tmp+j),(PVOID)":1:0:0",6); j+=6; } tmp[j++] = szNames[i]; @@ -33,19 +33,19 @@ void loadSupportedProtocols() { proto = (pSupPro) mir_realloc(proto,sizeof(SupPro)*proto_cnt); memset(&proto[j],0,sizeof(SupPro)); proto[j].name = mir_strdup(protos[i]->szName); - if( szNames ) { - if( proto[j].name ) { + if ( szNames ) { + if ( proto[j].name ) { char tmp[128]; strcpy(tmp,proto[j].name); strcat(tmp,":"); LPSTR szName = strstr(szNames,tmp); - if( szName ) { + if ( szName ) { szName = strchr(szName,':'); - if( szName ) { + if ( szName ) { proto[j].inspecting = (*++szName == '1'); szName = strchr(szName,':'); - if( szName ) { + if ( szName ) { proto[j].split_on = atoi(++szName); proto[j].tsplit_on = proto[j].split_on; szName = strchr(szName,':'); - if( szName ) { + if ( szName ) { proto[j].split_off = atoi(++szName); proto[j].tsplit_off = proto[j].split_off; } } @@ -86,9 +86,9 @@ void MoveToFirstInFilterList(HANDLE hContact) { for(i=0;;i++) { mir_itoa(i,str,10); - if( DBGetContactSettingString(hContact,"_Filter",str,&dbv) ) break; - if( !strcmp(szModuleName,dbv.pszVal) ) { // нашли мой модуль - if( i==0 ) return; + if ( DBGetContactSettingString(hContact,"_Filter",str,&dbv) ) break; + if ( !strcmp(szModuleName,dbv.pszVal) ) { // нашли мой модуль + if ( i==0 ) return; DBGetContactSettingString(hContact,"_Filter","0",&dbv); DBWriteContactSettingString(hContact,"_Filter","0",szModuleName); DBWriteContactSettingString(hContact,"_Filter",str,dbv.pszVal); @@ -108,14 +108,14 @@ void MoveToLastInFilterList(HANDLE hContact) { for(i=0;;i++) { mir_itoa(i,str,10); - if( DBGetContactSettingString(hContact,"_Filter",str,&dbv) ) break; - if( !strcmp(szModuleName,dbv.pszVal) ) { // нашли мой модуль + if ( DBGetContactSettingString(hContact,"_Filter",str,&dbv) ) break; + if ( !strcmp(szModuleName,dbv.pszVal) ) { // нашли мой модуль j=i; } mir_free(dbv.pszVal); } i--; - if( j==i ) return; + if ( j==i ) return; mir_itoa(i,end,10); mir_itoa(j,str,10); DBGetContactSettingString(hContact,"_Filter",end,&dbv); @@ -137,7 +137,7 @@ pUinKey addContact(HANDLE hContact) { CallService(MS_PROTO_ADDTOCONTACT, (WPARAM)hContact, (LPARAM)szModuleName); MoveToLastInFilterList(hContact); for(j=0;jname, PS_GETCAPS, PFLAG_UNIQUEIDSETTING, 0); - if( uID==(LPSTR)CALLSERVICE_NOTFOUND ) uID = 0; // Billy_Bons - if( uID && DBGetContactSetting(hContact, ptr->name, uID, &dbv_uniqueid)==0 ) { + if ( uID==(LPSTR)CALLSERVICE_NOTFOUND ) uID = 0; // Billy_Bons + if ( uID && DBGetContactSetting(hContact, ptr->name, uID, &dbv_uniqueid)==0 ) { if (dbv_uniqueid.type == DBVT_WORD) sprintf(szUIN, "%u [%s]", dbv_uniqueid.wVal, ptr->name); else @@ -316,7 +316,7 @@ void getContactUinA(HANDLE hContact, LPSTR szUIN) { void getContactUin(HANDLE hContact, LPSTR szUIN) { getContactUinA(hContact, szUIN); - if( bCoreUnicode && *szUIN ) { + if ( bCoreUnicode && *szUIN ) { LPWSTR tmp = mir_a2u(szUIN); wcscpy((LPWSTR)szUIN, tmp); mir_free(tmp); -- cgit v1.2.3