summaryrefslogtreecommitdiff
path: root/plugins/YAMN/src/proto/pop3
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2013-02-12 20:44:55 +0000
committerGeorge Hazan <george.hazan@gmail.com>2013-02-12 20:44:55 +0000
commit82016434fff2eb8ed8288c0c45bc76a67574860d (patch)
treef0771b2391899c61960c27af13d5e046f0d087d2 /plugins/YAMN/src/proto/pop3
parentc989c00ce9e0a8422e7efb3c21350ca3f5276d86 (diff)
- fix for chinese in popups;
- own md5 module removed; - version bump; - code cleaning git-svn-id: http://svn.miranda-ng.org/main/trunk@3585 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/YAMN/src/proto/pop3')
-rw-r--r--plugins/YAMN/src/proto/pop3/pop3.cpp20
-rw-r--r--plugins/YAMN/src/proto/pop3/pop3.h2
-rw-r--r--plugins/YAMN/src/proto/pop3/pop3comm.cpp146
-rw-r--r--plugins/YAMN/src/proto/pop3/pop3opt.cpp46
4 files changed, 105 insertions, 109 deletions
diff --git a/plugins/YAMN/src/proto/pop3/pop3.cpp b/plugins/YAMN/src/proto/pop3/pop3.cpp
index 76c3e9645c..bae04363cb 100644
--- a/plugins/YAMN/src/proto/pop3/pop3.cpp
+++ b/plugins/YAMN/src/proto/pop3/pop3.cpp
@@ -28,10 +28,6 @@
#include "..\..\yamn.h"
#include "pop3.h"
-extern "C" {
-#include "../md5.h"
-}
-
extern void __stdcall SSL_DebugLog( const char *fmt, ... );
//--------------------------------------------------------------------------------------------------
@@ -47,7 +43,7 @@ char *CPop3Client::Connect(const char* servername,const int port,BOOL UseSSL, BO
if (Stopped) //check if we can work with this POP3 client session
throw POP3Error=(DWORD)EPOP3_STOPPED;
- if (NetClient!=NULL)
+ if (NetClient != NULL)
delete NetClient;
SSL=UseSSL;
NetClient=new CNLClient;
@@ -114,7 +110,7 @@ char* CPop3Client::RecvRest(char* prev,int mode,int size)
{ //if not found
if (NetClient->Stopped) //check if we can work with this POP3 client session
{
- if (PrevString!=NULL)
+ if (PrevString != NULL)
free(PrevString);
throw POP3Error=(DWORD)EPOP3_STOPPED;
}
@@ -252,13 +248,13 @@ char* CPop3Client::APOP(char* name, char* pw, char* timestamp)
if (timestamp==NULL)
throw POP3Error=(DWORD)EPOP3_APOP;
- MD5Context ctx;
- MD5Init(&ctx);
- MD5Update(&ctx,(const unsigned char *)timestamp,(unsigned int)strlen(timestamp));
- MD5Update(&ctx,(const unsigned char *)pw,(unsigned int)strlen(pw));
- MD5Final(digest,&ctx);
+ mir_md5_state_s ctx;
+ mir_md5_init(&ctx);
+ mir_md5_append(&ctx,(const unsigned char *)timestamp,(unsigned int)strlen(timestamp));
+ mir_md5_append(&ctx,(const unsigned char *)pw,(unsigned int)strlen(pw));
+ mir_md5_finish(&ctx, digest);
hexdigest[0]='\0';
- for (int i=0; i<16; i++) {
+ for (int i=0; i < 16; i++) {
char tmp[4];
sprintf(tmp, "%02x", digest[i]);
strcat(hexdigest, tmp);
diff --git a/plugins/YAMN/src/proto/pop3/pop3.h b/plugins/YAMN/src/proto/pop3/pop3.h
index 1f7f2ea737..4d49f80bec 100644
--- a/plugins/YAMN/src/proto/pop3/pop3.h
+++ b/plugins/YAMN/src/proto/pop3/pop3.h
@@ -23,7 +23,7 @@ class CPop3Client
{
public:
CPop3Client(): NetClient(NULL), Stopped(FALSE) {}
- ~CPop3Client() {if (NetClient!=NULL) delete NetClient;}
+ ~CPop3Client() {if (NetClient != NULL) delete NetClient;}
char* Connect(const char* servername,const int port=110,BOOL UseSSL=FALSE, BOOL NoTLS=FALSE);
char* RecvRest(char* prev,int mode,int size=65536);
diff --git a/plugins/YAMN/src/proto/pop3/pop3comm.cpp b/plugins/YAMN/src/proto/pop3/pop3comm.cpp
index 2139a93375..7573484e8c 100644
--- a/plugins/YAMN/src/proto/pop3/pop3comm.cpp
+++ b/plugins/YAMN/src/proto/pop3/pop3comm.cpp
@@ -157,7 +157,7 @@ CPOP3Account::CPOP3Account()
CPOP3Account::~CPOP3Account()
{
CloseHandle(UseInternetFree);
- if (InternetQueries!=NULL)
+ if (InternetQueries != NULL)
delete InternetQueries;
}
@@ -167,7 +167,7 @@ HACCOUNT WINAPI CreatePOP3Account(HYAMNPROTOPLUGIN Plugin,DWORD CAccountVersion)
//But this is internal plugin, so YAMN's CAccount structure and our CAccount structure are
//the same, so we do not need to test version. Otherwise, if CAccount version does not match
//in your plugin, you should return NULL, like this:
-// if (CAccountVersion!=YAMN_ACCOUNTVERSION) return NULL;
+// if (CAccountVersion != YAMN_ACCOUNTVERSION) return NULL;
//Now it is needed to construct our POP3 account and return its handle
return (HACCOUNT)new struct CPOP3Account();
@@ -181,7 +181,7 @@ void WINAPI DeletePOP3Account(HACCOUNT Which)
void WINAPI StopPOP3Account(HACCOUNT Which)
{
((HPOP3ACCOUNT)Which)->Client.Stopped=TRUE;
- if (((HPOP3ACCOUNT)Which)->Client.NetClient!=NULL) //we should inform also network client. Usefull only when network client implements this feature
+ if (((HPOP3ACCOUNT)Which)->Client.NetClient != NULL) //we should inform also network client. Usefull only when network client implements this feature
((HPOP3ACCOUNT)Which)->Client.NetClient->Stopped=TRUE;
}
@@ -263,7 +263,7 @@ int RegisterPOP3Plugin(WPARAM,LPARAM)
FileName = NULL;
return 0;
case EACC_SYSTEM:
- if (ERROR_FILE_NOT_FOUND!=GetLastError())
+ if (ERROR_FILE_NOT_FOUND != GetLastError())
{
TCHAR temp[1024] = {0};
mir_sntprintf(temp, SIZEOF(temp), _T("%s\n%s"),TranslateT("Reading file error. File already in use?"),FileName);
@@ -281,7 +281,7 @@ int RegisterPOP3Plugin(WPARAM,LPARAM)
DBVARIANT dbv;
char *szProto;
- for (Finder=POP3Plugin->FirstAccount;Finder!=NULL;Finder=Finder->Next)
+ for (Finder=POP3Plugin->FirstAccount;Finder != NULL;Finder=Finder->Next)
{
Finder->hContact = NULL;
hContact = db_find_first();
@@ -374,7 +374,7 @@ DWORD WINAPI ReadPOP3Options(HACCOUNT Which,char **Parser,char *End)
(*Parser)+=sizeof(DWORD);
if (*Parser>=End)
return EACC_FILECOMPATIBILITY;
- if (Ver!=POP3_FILEVERSION)
+ if (Ver != POP3_FILEVERSION)
return EACC_FILECOMPATIBILITY;
((HPOP3ACCOUNT)Which)->CP=*(WORD *)(*Parser);
@@ -395,7 +395,7 @@ HYAMNMAIL WINAPI CreatePOP3Mail(HACCOUNT Account,DWORD MailDataVersion)
//But this is internal plugin, so YAMN's MAILDATA structure and our MAILDATA structure are
//the same, so we do not need to test version. Otherwise, if MAILDATA version does not match
//in your plugin, you should return NULL, like this:
-// if (MailDataVersion!=YAMN_MAILDATAVERSION) return NULL;
+// if (MailDataVersion != YAMN_MAILDATAVERSION) return NULL;
//Now it is needed to construct our POP3 account and return its handle
if (NULL==(NewMail=new YAMNMAIL))
@@ -426,7 +426,7 @@ static void PostErrorProc(HPOP3ACCOUNT ActualAccount,void *ParamToBadConnection,
PPOP3_ERRORCODE ErrorCode;
//We store status before we do Quit(), because quit can destroy our errorcode status
- if (NULL!=(ErrorCode=new POP3_ERRORCODE))
+ if (NULL != (ErrorCode=new POP3_ERRORCODE))
{
ErrorCode->SSL=UseSSL;
ErrorCode->AppError=ActualAccount->SystemError;
@@ -440,7 +440,7 @@ static void PostErrorProc(HPOP3ACCOUNT ActualAccount,void *ParamToBadConnection,
try
{
DataRX=ActualAccount->Client.Quit();
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
}
catch(...)
@@ -502,7 +502,7 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
//First, we should compare our version of CheckParam structure, but here it is not needed, because YAMN and internal plugin
//have the same version. But your plugin should do that in this way:
- // if (((struct CheckParam *)WhichTemp)->Ver!=YAMN_CHECKVERSION)
+ // if (((struct CheckParam *)WhichTemp)->Ver != YAMN_CHECKVERSION)
// {
// SetEvent(((struct CheckParam *)WhichTemp)->ThreadRunningEV); //don't forget to unblock YAMN
// return (DWORD)-1; //ok, but we should return value.
@@ -519,13 +519,13 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
#endif
SCInc(ActualAccount->UsingThreads);
//Unblock YAMN, signal that we have copied all parameters from YAMN thread stack
- if (INVALID_HANDLE_VALUE!=WhichTemp->ThreadRunningEV)
+ if (INVALID_HANDLE_VALUE != WhichTemp->ThreadRunningEV)
SetEvent(WhichTemp->ThreadRunningEV);
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"CheckPOP3:ActualAccountSO-read wait\n");
#endif
- if (WAIT_OBJECT_0!=WaitToRead(ActualAccount))
+ if (WAIT_OBJECT_0 != WaitToRead(ActualAccount))
{
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"CheckPOP3:ActualAccountSO-read wait failed\n");
@@ -598,7 +598,7 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
DataRX=MyClient->Connect(ActualCopied.ServerName,ActualCopied.ServerPort,ActualCopied.Flags & YAMN_ACC_SSL23,ActualCopied.Flags & YAMN_ACC_NOTLS);
char *timestamp=NULL;
- if (DataRX!=NULL)
+ if (DataRX != NULL)
{
if (ActualCopied.Flags & YAMN_ACC_APOP)
{
@@ -620,17 +620,17 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
if (ActualCopied.Flags & YAMN_ACC_APOP)
{
DataRX=MyClient->APOP(ActualCopied.ServerLogin,ActualCopied.ServerPasswd,timestamp);
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
delete[] timestamp;
} else {
DataRX=MyClient->User(ActualCopied.ServerLogin);
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
DataRX=MyClient->Pass(ActualCopied.ServerPasswd);
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
}
@@ -649,7 +649,7 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
DebugLog(DecodeFile,"<Msgs>%d</Msgs>\n",msgs);
DebugLog(DecodeFile,"</Extracting stat>\n");
#endif
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
for (i=0;i<msgs;i++)
@@ -678,7 +678,7 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
#ifdef DEBUG_DECODE
DebugLog(DecodeFile,"</Extracting list>\n");
#endif
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
@@ -690,14 +690,14 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
#ifdef DEBUG_DECODE
DebugLog(DecodeFile,"</Extracting UIDL>\n");
#endif
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
}
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"CheckPOP3:ActualAccountMsgsSO-write wait\n");
#endif
- if (WAIT_OBJECT_0!=MsgsWaitToWrite(ActualAccount))
+ if (WAIT_OBJECT_0 != MsgsWaitToWrite(ActualAccount))
{
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"CheckPOP3:ActualAccountMsgsSO-write wait failed\n");
@@ -708,10 +708,10 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
DebugLog(SynchroFile,"CheckPOP3:ActualAccountMsgsSO-write enter\n");
#endif
ActualAccount->LastChecked=now;
- for (MsgQueuePtr=(HYAMNMAIL)ActualAccount->Mails;MsgQueuePtr!=NULL;MsgQueuePtr=MsgQueuePtr->Next) {
+ for (MsgQueuePtr=(HYAMNMAIL)ActualAccount->Mails;MsgQueuePtr != NULL;MsgQueuePtr=MsgQueuePtr->Next) {
if (MsgQueuePtr->Flags&YAMN_MSG_BODYREQUESTED) {
HYAMNMAIL NewMsgsPtr=NULL;
- for (NewMsgsPtr=(HYAMNMAIL)NewMails;NewMsgsPtr!=NULL;NewMsgsPtr=NewMsgsPtr->Next) {
+ for (NewMsgsPtr=(HYAMNMAIL)NewMails;NewMsgsPtr != NULL;NewMsgsPtr=NewMsgsPtr->Next) {
if (!strcmp(MsgQueuePtr->ID,NewMsgsPtr->ID)) {
TCHAR accstatus[512];
wsprintf(accstatus,TranslateT("Reading body %s"),NewMsgsPtr->ID);
@@ -721,7 +721,7 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
DebugLog(DecodeFile,"<Reading body>\n");
DebugLog(DecodeFile,"<Header>%s</Header>\n",DataRX);
#endif
- if (DataRX!=NULL)
+ if (DataRX != NULL)
{
Temp=DataRX;
while((Temp<DataRX+MyClient->NetClient->Rcv) && (WS(Temp) || ENDLINE(Temp))) Temp++;
@@ -734,12 +734,12 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
continue;
//delete all the headers of the old mail MsgQueuePtr->MailData->TranslatedHeader
struct CMimeItem *TH = MsgQueuePtr->MailData->TranslatedHeader;
- if (TH) for (;MsgQueuePtr->MailData->TranslatedHeader!=NULL;)
+ if (TH) for (;MsgQueuePtr->MailData->TranslatedHeader != NULL;)
{
TH=TH->Next;
- if (MsgQueuePtr->MailData->TranslatedHeader->name!=NULL)
+ if (MsgQueuePtr->MailData->TranslatedHeader->name != NULL)
delete[] MsgQueuePtr->MailData->TranslatedHeader->name;
- if (MsgQueuePtr->MailData->TranslatedHeader->value!=NULL)
+ if (MsgQueuePtr->MailData->TranslatedHeader->value != NULL)
delete[] MsgQueuePtr->MailData->TranslatedHeader->value;
delete MsgQueuePtr->MailData->TranslatedHeader;
MsgQueuePtr->MailData->TranslatedHeader=TH;
@@ -753,7 +753,7 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
#endif
MsgQueuePtr->Flags|=YAMN_MSG_BODYRECEIVED;
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
break;
@@ -769,7 +769,7 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
DebugLog(SynchroFile,"CheckPOP3:ActualAccountMsgsSO-write done\n");
#endif
MsgsWriteDone(ActualAccount);
- for (MsgQueuePtr=(HYAMNMAIL)ActualAccount->Mails;MsgQueuePtr!=NULL;MsgQueuePtr=MsgQueuePtr->Next) {
+ for (MsgQueuePtr=(HYAMNMAIL)ActualAccount->Mails;MsgQueuePtr != NULL;MsgQueuePtr=MsgQueuePtr->Next) {
if ((MsgQueuePtr->Flags&YAMN_MSG_BODYREQUESTED) && (MsgQueuePtr->Flags&YAMN_MSG_BODYRECEIVED)) {
MsgQueuePtr->Flags&=~YAMN_MSG_BODYREQUESTED;
if (MsgQueuePtr->MsgWindow)
@@ -777,15 +777,15 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
}
}
- for (msgs=0,MsgQueuePtr=NewMails;MsgQueuePtr!=NULL;MsgQueuePtr=MsgQueuePtr->Next,msgs++); //get number of new mails
+ for (msgs=0,MsgQueuePtr=NewMails;MsgQueuePtr != NULL;MsgQueuePtr=MsgQueuePtr->Next,msgs++); //get number of new mails
try
{
TCHAR accstatus[512];
- for (i=0,MsgQueuePtr=NewMails;MsgQueuePtr!=NULL;i++)
+ for (i=0,MsgQueuePtr=NewMails;MsgQueuePtr != NULL;i++)
{
- BOOL autoretr = (ActualAccount->Flags & YAMN_ACC_BODY)!=0;
+ BOOL autoretr = (ActualAccount->Flags & YAMN_ACC_BODY) != 0;
DataRX=MyClient->Top(MsgQueuePtr->Number,autoretr?100:0);
wsprintf(accstatus,TranslateT("Reading new mail messages (%d%% done)"),100*i/msgs);
SetAccountStatus(ActualAccount,accstatus);
@@ -794,7 +794,7 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
DebugLog(DecodeFile,"<New mail>\n");
DebugLog(DecodeFile,"<Header>%s</Header>\n",DataRX);
#endif
- if (DataRX!=NULL)
+ if (DataRX != NULL)
{
Temp=DataRX;
while((Temp<DataRX+MyClient->NetClient->Rcv) && (WS(Temp) || ENDLINE(Temp))) Temp++;
@@ -821,7 +821,7 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
// CallService(MS_YAMN_FILTERMAIL,(WPARAM)ActualAccount,(LPARAM)MsgQueuePtr);
FilterMailSvc((WPARAM)ActualAccount,(LPARAM)MsgQueuePtr);
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
@@ -837,7 +837,7 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"CheckPOP3:ActualAccountMsgsSO-write wait\n");
#endif
- if (WAIT_OBJECT_0!=MsgsWaitToWrite(ActualAccount))
+ if (WAIT_OBJECT_0 != MsgsWaitToWrite(ActualAccount))
{
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"CheckPOP3:ActualAccountMsgsSO-write wait failed\n");
@@ -872,7 +872,7 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
if (0==SCGetNumber(ActualAccount->InternetQueries))
{
DataRX=MyClient->Quit();
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
MyClient->NetClient->Disconnect();
@@ -898,8 +898,8 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
YAMN_MAILBROWSERPARAM Param={(HANDLE)0,ActualAccount,ActualCopied.NFlags,ActualCopied.NNFlags,YAMNParam};
if (CheckFlags & YAMN_FORCECHECK)
- Param.nnflags|=YAMN_ACC_POP; //if force check, show popup anyway and if mailbrowser was opened, do not close
- Param.nnflags|= YAMN_ACC_MSGP; //do not close browser if already open
+ Param.nnflags |= YAMN_ACC_POP; //if force check, show popup anyway and if mailbrowser was opened, do not close
+ Param.nnflags |= YAMN_ACC_MSGP; //do not close browser if already open
CallService(MS_YAMN_MAILBROWSER,(WPARAM)&Param,(LPARAM)YAMN_MAILBROWSERVERSION);
}
SetContactStatus(ActualAccount,ActualAccount->isCounting?ID_STATUS_ONLINE:ID_STATUS_OFFLINE);
@@ -936,7 +936,7 @@ DWORD WINAPI SynchroPOP3(struct CheckParam * WhichTemp)
DeleteMIMEQueue(ActualAccount,NewMails);
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
switch(ActualAccount->SystemError)
@@ -994,7 +994,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
//First, we should compare our version of DeleteParam structure, but here it is not needed, because YAMN and internal plugin
//have the same version. But your plugin should do that in this way:
- // if (((struct DeleteParam *)WhichTemp)->Ver!=YAMN_DELETEVERSION)
+ // if (((struct DeleteParam *)WhichTemp)->Ver != YAMN_DELETEVERSION)
// {
// SetEvent(((struct DeleteParam *)WhichTemp)->ThreadRunningEV); //don't forget to unblock YAMN
// return (DWORD)-1; //ok, but we should return value.
@@ -1010,13 +1010,13 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
DebugLog(SynchroFile,"DeleteMailsPOP3:Incrementing \"using threads\" %x (account %x)\n",ActualAccount->UsingThreads,ActualAccount);
#endif
SCInc(ActualAccount->UsingThreads);
- if (INVALID_HANDLE_VALUE!=WhichTemp->ThreadRunningEV)
+ if (INVALID_HANDLE_VALUE != WhichTemp->ThreadRunningEV)
SetEvent(WhichTemp->ThreadRunningEV);
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"DeleteMailsPOP3:ActualAccountSO-read wait\n");
#endif
- if (WAIT_OBJECT_0!=WaitToRead(ActualAccount))
+ if (WAIT_OBJECT_0 != WaitToRead(ActualAccount))
{
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"DeleteMailsPOP3:ActualAccountSO-read wait failed\n");
@@ -1032,7 +1032,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
#endif
if (NULL==(DeleteMails=(HYAMNMAIL)CreateNewDeleteQueue((HYAMNMAIL)ActualAccount->Mails))) //if there's no mail for deleting, return
{
- if (POP3_DELETEFROMCHECK!=POP3PluginParam) //We do not wait for free internet when calling from SynchroPOP3. It is because UseInternetFree is blocked
+ if (POP3_DELETEFROMCHECK != POP3PluginParam) //We do not wait for free internet when calling from SynchroPOP3. It is because UseInternetFree is blocked
{
YAMN_MAILBROWSERPARAM Param={(HANDLE)0,ActualAccount,YAMN_ACC_MSGP,YAMN_ACC_MSGP,YAMNParam}; //Just update the window
@@ -1066,7 +1066,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
ReadDone(ActualAccount);
SCInc(ActualAccount->InternetQueries); //This is POP3-internal SCOUNTER, we set another thread wait for this account to be connected to inet
- if (POP3_DELETEFROMCHECK!=POP3PluginParam) //We do not wait for free internet when calling from SynchroPOP3. It is because UseInternetFree is blocked
+ if (POP3_DELETEFROMCHECK != POP3PluginParam) //We do not wait for free internet when calling from SynchroPOP3. It is because UseInternetFree is blocked
{
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"DeleteMailsPOP3:InternetFreeEV-wait\n");
@@ -1092,7 +1092,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
DataRX=MyClient->Connect(ActualCopied.ServerName,ActualCopied.ServerPort,ActualCopied.Flags & YAMN_ACC_SSL23,ActualCopied.Flags & YAMN_ACC_NOTLS);
char *timestamp=NULL;
- if (DataRX!=NULL) {
+ if (DataRX != NULL) {
if (ActualAccount->Flags & YAMN_ACC_APOP) {
char *lpos=strchr(DataRX,'<');
char *rpos=strchr(DataRX,'>');
@@ -1111,17 +1111,17 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
if (ActualAccount->Flags & YAMN_ACC_APOP)
{
DataRX=MyClient->APOP(ActualCopied.ServerLogin,ActualCopied.ServerPasswd,timestamp);
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
delete[] timestamp;
} else {
DataRX=MyClient->User(ActualCopied.ServerLogin);
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
DataRX=MyClient->Pass(ActualCopied.ServerPasswd);
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
}
@@ -1130,7 +1130,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
#ifdef DEBUG_DECODE
DebugLog(DecodeFile,"<--------Deleting requested mails-------->\n");
#endif
- if (POP3_DELETEFROMCHECK!=POP3PluginParam) //We do not need to get mails on server as we have already it from check function
+ if (POP3_DELETEFROMCHECK != POP3PluginParam) //We do not need to get mails on server as we have already it from check function
{
SetAccountStatus(ActualAccount,TranslateT("Deleting requested mails"));
@@ -1145,7 +1145,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
DebugLog(DecodeFile,"<Msgs>%d</Msgs>\n",msgs);
DebugLog(DecodeFile,"</Extracting stat>\n");
#endif
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
for (i=0;i<msgs;i++)
@@ -1174,7 +1174,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
#ifdef DEBUG_DECODE
DebugLog(DecodeFile,"</Extracting UIDL>\n");
#endif
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
// we get "new mails" on server (NewMails will contain all mails on server not found in DeleteMails)
@@ -1187,7 +1187,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"DeleteMailsPOP3:ActualAccountMsgsSO-write wait\n");
#endif
- if (WAIT_OBJECT_0!=MsgsWaitToWrite(ActualAccount))
+ if (WAIT_OBJECT_0 != MsgsWaitToWrite(ActualAccount))
{
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"DeleteMailsPOP3:ActualAccountMsgsSO-write wait failed\n");
@@ -1203,7 +1203,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
{
HYAMNMAIL Temp;
- for (i=0,MsgQueuePtr=DeleteMails;MsgQueuePtr!=NULL;i++)
+ for (i=0,MsgQueuePtr=DeleteMails;MsgQueuePtr != NULL;i++)
{
if (!(MsgQueuePtr->Flags & YAMN_MSG_VIRTUAL)) //of course we can only delete real mails, not virtual
{
@@ -1229,7 +1229,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
}
MsgQueuePtr=Temp;
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
}
@@ -1246,7 +1246,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
throw; //and go to the main exception handling
}
- if (NewMails!=NULL)
+ if (NewMails != NULL)
// in ActualAccount->Mails we have all mails stored before calling this function
// in NewMails we have all mails not found in DeleteMails (in other words: we performed new ID checking and we
// stored all mails found on server, then we deleted the ones we wanted to delete in this function
@@ -1255,7 +1255,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
SynchroMessages(ActualAccount,(HYAMNMAIL *)&ActualAccount->Mails,NULL,(HYAMNMAIL *)&NewMails,NULL);
// Now ActualAccount->Mails contains all mails when calling this function except the ones, we wanted to delete (these are in DeleteMails)
// And in NewMails we have new mails (if any)
- else if (POP3_DELETEFROMCHECK!=POP3PluginParam)
+ else if (POP3_DELETEFROMCHECK != POP3PluginParam)
{
DeleteMIMEQueue(ActualAccount,(HYAMNMAIL)ActualAccount->Mails);
ActualAccount->Mails=NULL;
@@ -1280,7 +1280,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
// if there is no waiting thread for internet connection close it
// else leave connection open
// if this functin was called from SynchroPOP3, then do not try to disconnect
- if (POP3_DELETEFROMCHECK!=POP3PluginParam)
+ if (POP3_DELETEFROMCHECK != POP3PluginParam)
{
YAMN_MAILBROWSERPARAM Param={(HANDLE)0,ActualAccount,ActualCopied.NFlags,YAMN_ACC_MSGP,YAMNParam};
@@ -1289,7 +1289,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
if (0==SCGetNumber(ActualAccount->InternetQueries))
{
DataRX=MyClient->Quit();
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
DataRX=NULL;
MyClient->NetClient->Disconnect();
@@ -1316,7 +1316,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
#ifdef DEBUG_COMM
DebugLog(CommFile,"ERROR %x\n",ErrorCode);
#endif
- if (DataRX!=NULL)
+ if (DataRX != NULL)
free(DataRX);
switch(ActualAccount->SystemError)
{
@@ -1328,7 +1328,7 @@ DWORD WINAPI DeleteMailsPOP3(struct DeleteParam *WhichTemp)
PostErrorProc(ActualAccount,YAMNParam,POP3PluginParam,MyClient->SSL); //it closes internet connection too
}
- if (UsingInternet && (POP3_DELETEFROMCHECK!=POP3PluginParam)) //if our thread still uses internet and it is needed to release internet
+ if (UsingInternet && (POP3_DELETEFROMCHECK != POP3PluginParam)) //if our thread still uses internet and it is needed to release internet
{
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"CheckPOP3:InternetFreeEV-done\n");
@@ -1364,11 +1364,11 @@ void ExtractStat(char *stream,int len,int *mboxsize,int *mails)
while(!WS(finder)) finder++;
while(WS(finder)) finder++;
}
- if (1!=sscanf(finder,"%d",mails))
+ if (1 != sscanf(finder,"%d",mails))
throw (DWORD)EPOP3_STAT;
while(!WS(finder)) finder++;
while(WS(finder)) finder++;
- if (1!=sscanf(finder,"%d",mboxsize))
+ if (1 != sscanf(finder,"%d",mboxsize))
throw (DWORD)EPOP3_STAT;
}
void ExtractMail(char *stream,int len,HYAMNMAIL queue)
@@ -1390,20 +1390,20 @@ void ExtractMail(char *stream,int len,HYAMNMAIL queue)
DebugLog(DecodeFile,"<Message>\n");
#endif
while(WS(finder)) finder++; //jump whitespace
- if (1!=sscanf(finder,"%d",&msgnr))
+ if (1 != sscanf(finder,"%d",&msgnr))
throw (DWORD)EPOP3_UIDL;
#ifdef DEBUG_DECODE
DebugLog(DecodeFile,"<Nr>%d</Nr>\n",msgnr);
#endif
-// for (i=1,queueptr=queue;(queueptr->Next!=NULL) && (i<msgnr);queueptr=queueptr->Next,i++);
-// if (i!=msgnr)
+// for (i=1,queueptr=queue;(queueptr->Next != NULL) && (i<msgnr);queueptr=queueptr->Next,i++);
+// if (i != msgnr)
// throw (DWORD)EPOP3_UIDL;
while(!WS(finder)) finder++; //jump characters
while(WS(finder)) finder++; //jump whitespace
finderend=finder+1;
while(!WS(finderend) && !ENDLINE(finderend)) finderend++;
queueptr->ID=new char[finderend-finder+1];
- for (i=0;finder!=finderend;finder++,i++)
+ for (i=0;finder != finderend;finder++,i++)
queueptr->MailData->Body[i]=*finder;
queueptr->MailData->Body[i]=0; //ends string
queueptr->Number=msgnr;
@@ -1435,20 +1435,20 @@ void ExtractUIDL(char *stream,int len,HYAMNMAIL queue)
DebugLog(DecodeFile,"<Message>\n");
#endif
while(WS(finder)) finder++; //jump whitespace
- if (1!=sscanf(finder,"%d",&msgnr))
+ if (1 != sscanf(finder,"%d",&msgnr))
throw (DWORD)EPOP3_UIDL;
#ifdef DEBUG_DECODE
DebugLog(DecodeFile,"<Nr>%d</Nr>\n",msgnr);
#endif
-// for (i=1,queueptr=queue;(queueptr->Next!=NULL) && (i<msgnr);queueptr=queueptr->Next,i++);
-// if (i!=msgnr)
+// for (i=1,queueptr=queue;(queueptr->Next != NULL) && (i<msgnr);queueptr=queueptr->Next,i++);
+// if (i != msgnr)
// throw (DWORD)EPOP3_UIDL;
while(!WS(finder)) finder++; //jump characters
while(WS(finder)) finder++; //jump whitespace
finderend=finder+1;
while(!WS(finderend) && !ENDLINE(finderend)) finderend++;
queueptr->ID=new char[finderend-finder+1];
- for (i=0;finder!=finderend;finder++,i++)
+ for (i=0;finder != finderend;finder++,i++)
queueptr->ID[i]=*finder;
queueptr->ID[i]=0; //ends string
queueptr->Number=msgnr;
@@ -1480,19 +1480,19 @@ void ExtractList(char *stream,int len,HYAMNMAIL queue)
DebugLog(DecodeFile,"<Message>\n",NULL,0);
#endif
while(WS(finder)) finder++; //jump whitespace
- if (1!=sscanf(finder,"%d",&msgnr)) //message nr.
+ if (1 != sscanf(finder,"%d",&msgnr)) //message nr.
throw (DWORD)EPOP3_LIST;
#ifdef DEBUG_DECODE
DebugLog(DecodeFile,"<Nr>%d</Nr>\n",msgnr);
#endif
- for (i=1,queueptr=queue;(queueptr->Next!=NULL) && (i<msgnr);queueptr=queueptr->Next,i++);
- if (i!=msgnr)
+ for (i=1,queueptr=queue;(queueptr->Next != NULL) && (i<msgnr);queueptr=queueptr->Next,i++);
+ if (i != msgnr)
throw (DWORD)EPOP3_LIST;
while(!WS(finder)) finder++; //jump characters
while(WS(finder)) finder++; //jump whitespace
finderend=finder+1;
- if (1!=sscanf(finder,"%d",&queueptr->MailData->Size))
+ if (1 != sscanf(finder,"%d",&queueptr->MailData->Size))
throw (DWORD)EPOP3_LIST;
#ifdef DEBUG_DECODE
DebugLog(DecodeFile,"<Nr>%d</Nr>\n",queueptr->MailData->Size);
diff --git a/plugins/YAMN/src/proto/pop3/pop3opt.cpp b/plugins/YAMN/src/proto/pop3/pop3opt.cpp
index f49033043b..5f0cf9230e 100644
--- a/plugins/YAMN/src/proto/pop3/pop3opt.cpp
+++ b/plugins/YAMN/src/proto/pop3/pop3opt.cpp
@@ -96,7 +96,7 @@ INT_PTR CALLBACK DlgProcPluginOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lParam
break;
id=SendMessage(hCombo,CB_GETITEMDATA,(WPARAM)index,0);
EnterCriticalSection(&PluginRegCS);
- for (PParser=FirstProtoPlugin;PParser!=NULL;PParser=PParser->Next)
+ for (PParser=FirstProtoPlugin;PParser != NULL;PParser=PParser->Next)
if (id==(INT_PTR)PParser->Plugin)
{
SetDlgItemTextA(hDlg,IDC_STVER,PParser->Plugin->PluginInfo->Ver);
@@ -106,7 +106,7 @@ INT_PTR CALLBACK DlgProcPluginOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lParam
SetDlgItemTextA(hDlg,IDC_STWWW,PParser->Plugin->PluginInfo->WWW == NULL ? "" : PParser->Plugin->PluginInfo->WWW);
break;
}
- for (FParser=FirstFilterPlugin;FParser!=NULL;FParser=FParser->Next)
+ for (FParser=FirstFilterPlugin;FParser != NULL;FParser=FParser->Next)
if (id==(INT_PTR)FParser->Plugin)
{
SetDlgItemTextA(hDlg,IDC_STVER,FParser->Plugin->PluginInfo->Ver);
@@ -677,7 +677,7 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara
DebugLog(SynchroFile,"Options:INITDIALOG:AccountBrowserSO-read enter\n");
#endif
- for (ActualAccount=(HPOP3ACCOUNT)POP3Plugin->FirstAccount;ActualAccount!=NULL;ActualAccount=(HPOP3ACCOUNT)ActualAccount->Next)
+ for (ActualAccount=(HPOP3ACCOUNT)POP3Plugin->FirstAccount;ActualAccount != NULL;ActualAccount=(HPOP3ACCOUNT)ActualAccount->Next)
if (ActualAccount->Name != NULL)
SendDlgItemMessageA(hDlg,IDC_COMBOACCOUNT,CB_ADDSTRING,0,(LPARAM)ActualAccount->Name);
@@ -762,7 +762,7 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara
break;
case CBN_SELCHANGE:
- if (CB_ERR!=(Result=SendDlgItemMessage(hDlg,IDC_COMBOACCOUNT,CB_GETCURSEL,0,0)))
+ if (CB_ERR != (Result=SendDlgItemMessage(hDlg,IDC_COMBOACCOUNT,CB_GETCURSEL,0,0)))
SendDlgItemMessageA(hDlg,IDC_COMBOACCOUNT,CB_GETLBTEXT,(WPARAM)Result,(LPARAM)DlgInput);
if ((Result==CB_ERR) || (NULL==(ActualAccount=(HPOP3ACCOUNT)CallService(MS_YAMN_FINDACCOUNTBYNAME,(WPARAM)POP3Plugin,(LPARAM)DlgInput)))) {
@@ -834,7 +834,7 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara
case IDC_CPFT:
case IDC_CPNB:
case IDC_CPNT:
- if (HIWORD(wParam)!=CPN_COLOURCHANGED)
+ if (HIWORD(wParam) != CPN_COLOURCHANGED)
break;
case IDC_CHECKKBN:
@@ -902,7 +902,7 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara
|| (NULL==(ActualAccount=(HPOP3ACCOUNT)CallService(MS_YAMN_FINDACCOUNTBYNAME,(WPARAM)POP3Plugin,(LPARAM)DlgInput))))
return TRUE;
- if (IDOK!=MessageBox(hDlg,TranslateT("Do you really want to delete this account?"),TranslateT("Delete account confirmation"),MB_OKCANCEL | MB_ICONWARNING))
+ if (IDOK != MessageBox(hDlg,TranslateT("Do you really want to delete this account?"),TranslateT("Delete account confirmation"),MB_OKCANCEL | MB_ICONWARNING))
return TRUE;
DlgSetItemTextT(hDlg, IDC_STTIMELEFT, TranslateT("Please wait while no account is in use."));
@@ -1025,7 +1025,7 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"Options:APPLY:ActualAccountSO-write wait\n");
#endif
- if (WAIT_OBJECT_0!=WaitToWrite(ActualAccount))
+ if (WAIT_OBJECT_0 != WaitToWrite(ActualAccount))
{
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"Options:APPLY:ActualAccountSO-write wait failed\n");
@@ -1049,31 +1049,31 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara
strcpy(ActualAccount->Name,Text);
GetDlgItemTextA(hDlg,IDC_EDITSERVER,Text,sizeof(Text));
- if (NULL!=ActualAccount->Server->Name)
+ if (NULL != ActualAccount->Server->Name)
delete[] ActualAccount->Server->Name;
ActualAccount->Server->Name=new char[ strlen(Text)+1];
strcpy(ActualAccount->Server->Name,Text);
GetDlgItemTextA(hDlg,IDC_EDITLOGIN,Text,sizeof(Text));
- if (NULL!=ActualAccount->Server->Login)
+ if (NULL != ActualAccount->Server->Login)
delete[] ActualAccount->Server->Login;
ActualAccount->Server->Login=new char[ strlen(Text)+1];
strcpy(ActualAccount->Server->Login,Text);
GetDlgItemTextA(hDlg,IDC_EDITPASS,Text,sizeof(Text));
- if (NULL!=ActualAccount->Server->Passwd)
+ if (NULL != ActualAccount->Server->Passwd)
delete[] ActualAccount->Server->Passwd;
ActualAccount->Server->Passwd=new char[ strlen(Text)+1];
strcpy(ActualAccount->Server->Passwd,Text);
GetDlgItemTextW(hDlg,IDC_EDITAPP,TextW,SIZEOF(TextW));
- if (NULL!=ActualAccount->NewMailN.App)
+ if (NULL != ActualAccount->NewMailN.App)
delete[] ActualAccount->NewMailN.App;
ActualAccount->NewMailN.App=new WCHAR[wcslen(TextW)+1];
wcscpy(ActualAccount->NewMailN.App,TextW);
GetDlgItemTextW(hDlg,IDC_EDITAPPPARAM,TextW,SIZEOF(TextW));
- if (NULL!=ActualAccount->NewMailN.AppParam)
+ if (NULL != ActualAccount->NewMailN.AppParam)
delete[] ActualAccount->NewMailN.AppParam;
ActualAccount->NewMailN.AppParam=new WCHAR[wcslen(TextW)+1];
wcscpy(ActualAccount->NewMailN.AppParam,TextW);
@@ -1156,9 +1156,9 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara
HPOP3ACCOUNT temp = ActualAccount;
SendDlgItemMessage(hDlg,IDC_COMBOACCOUNT,CB_RESETCONTENT,0,0);
- if (POP3Plugin->FirstAccount!=NULL)
- for (ActualAccount=(HPOP3ACCOUNT)POP3Plugin->FirstAccount;ActualAccount!=NULL;ActualAccount=(HPOP3ACCOUNT)ActualAccount->Next)
- if (ActualAccount->Name!=NULL)
+ if (POP3Plugin->FirstAccount != NULL)
+ for (ActualAccount=(HPOP3ACCOUNT)POP3Plugin->FirstAccount;ActualAccount != NULL;ActualAccount=(HPOP3ACCOUNT)ActualAccount->Next)
+ if (ActualAccount->Name != NULL)
SendDlgItemMessageA(hDlg,IDC_COMBOACCOUNT,CB_ADDSTRING,0,(LPARAM)ActualAccount->Name);
ActualAccount = temp;
@@ -1198,9 +1198,9 @@ INT_PTR CALLBACK DlgProcPOP3AccPopup(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPa
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"Options:INITDIALOG:AccountBrowserSO-read enter\n");
#endif
- if (POP3Plugin->FirstAccount!=NULL)
- for (ActualAccount=(HPOP3ACCOUNT)POP3Plugin->FirstAccount;ActualAccount!=NULL;ActualAccount=(HPOP3ACCOUNT)ActualAccount->Next)
- if (ActualAccount->Name!=NULL)
+ if (POP3Plugin->FirstAccount != NULL)
+ for (ActualAccount=(HPOP3ACCOUNT)POP3Plugin->FirstAccount;ActualAccount != NULL;ActualAccount=(HPOP3ACCOUNT)ActualAccount->Next)
+ if (ActualAccount->Name != NULL)
SendDlgItemMessageA(hDlg,IDC_COMBOACCOUNT,CB_ADDSTRING,0,(LPARAM)ActualAccount->Name);
#ifdef DEBUG_SYNCHRO
DebugLog(SynchroFile,"Options:INITDIALOG:AccountBrowserSO-read done\n");
@@ -1228,9 +1228,9 @@ INT_PTR CALLBACK DlgProcPOP3AccPopup(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPa
HPOP3ACCOUNT temp = ActualAccount;
SendDlgItemMessage(hDlg,IDC_COMBOACCOUNT,CB_RESETCONTENT,0,0);
- if (POP3Plugin->FirstAccount!=NULL)
- for (ActualAccount=(HPOP3ACCOUNT)POP3Plugin->FirstAccount;ActualAccount!=NULL;ActualAccount=(HPOP3ACCOUNT)ActualAccount->Next)
- if (ActualAccount->Name!=NULL)
+ if (POP3Plugin->FirstAccount != NULL)
+ for (ActualAccount=(HPOP3ACCOUNT)POP3Plugin->FirstAccount;ActualAccount != NULL;ActualAccount=(HPOP3ACCOUNT)ActualAccount->Next)
+ if (ActualAccount->Name != NULL)
SendDlgItemMessageA(hDlg,IDC_COMBOACCOUNT,CB_ADDSTRING,0,(LPARAM)ActualAccount->Name);
ActualAccount = temp;
@@ -1279,7 +1279,7 @@ INT_PTR CALLBACK DlgProcPOP3AccPopup(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPa
}
break;
case CBN_SELCHANGE:
- if (CB_ERR!=(Result=SendDlgItemMessage(hDlg,IDC_COMBOACCOUNT,CB_GETCURSEL,0,0)))
+ if (CB_ERR != (Result=SendDlgItemMessage(hDlg,IDC_COMBOACCOUNT,CB_GETCURSEL,0,0)))
SendDlgItemMessageA(hDlg,IDC_COMBOACCOUNT,CB_GETLBTEXT,(WPARAM)Result,(LPARAM)DlgInput);
if ((Result==CB_ERR) || (NULL==(ActualAccount=(HPOP3ACCOUNT)CallService(MS_YAMN_FINDACCOUNTBYNAME,(WPARAM)POP3Plugin,(LPARAM)DlgInput))))
{
@@ -1310,7 +1310,7 @@ INT_PTR CALLBACK DlgProcPOP3AccPopup(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPa
case IDC_CPFT:
case IDC_CPNB:
case IDC_CPNT:
- if (HIWORD(wParam)!=CPN_COLOURCHANGED)
+ if (HIWORD(wParam) != CPN_COLOURCHANGED)
break;
case IDC_CHECKCOL:
case IDC_CHECKFCOL: