From e33349427eadab1658c54655db3190fc7329c47e Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 8 Oct 2023 19:01:47 +0300 Subject: compilation fix --- protocols/YAMN/src/mails/mails.cpp | 16 ++++++++-------- protocols/YAMN/src/proto/pop3/pop3comm.cpp | 6 ++---- protocols/YAMN/src/protoplugin.cpp | 2 +- protocols/YAMN/src/stdafx.h | 2 +- 4 files changed, 12 insertions(+), 14 deletions(-) diff --git a/protocols/YAMN/src/mails/mails.cpp b/protocols/YAMN/src/mails/mails.cpp index 606a21ebbd..1bcbc60242 100644 --- a/protocols/YAMN/src/mails/mails.cpp +++ b/protocols/YAMN/src/mails/mails.cpp @@ -70,7 +70,7 @@ int DeleteAccountMail(YAMN_PROTOPLUGIN *Plugin, HYAMNMAIL OldMail) // Appends second MIME mail queue to the first one // Only finds the end of first queue and its Next memember repoints to second one -void WINAPI AppendQueueFcn(HYAMNMAIL first, HYAMNMAIL second) +void AppendQueueFcn(HYAMNMAIL first, HYAMNMAIL second) { HYAMNMAIL Finder = first; while (Finder->Next != nullptr) Finder = Finder->Next; @@ -97,7 +97,7 @@ void WINAPI AppendQueueFcn(HYAMNMAIL first, HYAMNMAIL second) // 1. delete (or move to RemovedOld queue if RemovedOld is not NULL) all mails from OldQueue not found in NewQueue // 2. delete (or move to RemovedNew queue if RemovedNew is not NULL) all mails from NewQueue found in OldQueue -void WINAPI SynchroMessagesFcn(CAccount *Account, HYAMNMAIL *OldQueue, HYAMNMAIL *RemovedOld, HYAMNMAIL *NewQueue, HYAMNMAIL *RemovedNew) +void SynchroMessagesFcn(CAccount *Account, HYAMNMAIL *OldQueue, HYAMNMAIL *RemovedOld, HYAMNMAIL *NewQueue, HYAMNMAIL *RemovedNew) // deletes messages from new queue, if they are old // it also deletes messages from old queue, if they are not in mailbox anymore // "YAMN_MSG_DELETED" messages in old queue remain in old queue (are never removed, although they are not in new queue) @@ -188,7 +188,7 @@ void WINAPI SynchroMessagesFcn(CAccount *Account, HYAMNMAIL *OldQueue, HYAMNMAIL // Account- account who owns mails // From- first mail in queue, which is going to delete -void WINAPI DeleteMessagesToEndFcn(CAccount *Account, HYAMNMAIL From) +void DeleteMessagesToEndFcn(CAccount *Account, HYAMNMAIL From) { HYAMNMAIL Temp; while (From != nullptr) { @@ -204,7 +204,7 @@ void WINAPI DeleteMessagesToEndFcn(CAccount *Account, HYAMNMAIL From) // Which- mail to delete // mode- nonzero if you want to decrement numbers in messages that are bigger than the one in Which mail, 0 if not -void WINAPI DeleteMessageFromQueueFcn(HYAMNMAIL *From, HYAMNMAIL Which, int mode) +void DeleteMessageFromQueueFcn(HYAMNMAIL *From, HYAMNMAIL Which, int mode) { uint32_t Number = Which->Number; HYAMNMAIL Parser; @@ -239,7 +239,7 @@ void DeleteMessagesFromQueue(HYAMNMAIL *From, HYAMNMAIL Which, int mode = 0) // ID- pointer to ID // returns pointer to found message, NULL if not found -HYAMNMAIL WINAPI FindMessageByIDFcn(HYAMNMAIL From, char *ID) +HYAMNMAIL FindMessageByIDFcn(HYAMNMAIL From, char *ID) { HYAMNMAIL Browser; @@ -256,7 +256,7 @@ HYAMNMAIL WINAPI FindMessageByIDFcn(HYAMNMAIL From, char *ID) // len- length of stream // head- function fills this pointer to first header item in queue -void WINAPI TranslateHeaderFcn(char *stream, int len, struct CMimeItem **head) +void TranslateHeaderFcn(char *stream, int len, struct CMimeItem **head) { try { char *finder = stream; @@ -343,7 +343,7 @@ void WINAPI TranslateHeaderFcn(char *stream, int len, struct CMimeItem **head) // Function does not copy the whole mails, it copies only ID string. And ID is copied as string, so // you can use this fcn only if you have your ID as pointer to char string ended with zero character -HYAMNMAIL WINAPI CreateNewDeleteQueueFcn(HYAMNMAIL From) +HYAMNMAIL CreateNewDeleteQueueFcn(HYAMNMAIL From) { HYAMNMAIL FirstMail, Browser = nullptr; @@ -375,7 +375,7 @@ HYAMNMAIL WINAPI CreateNewDeleteQueueFcn(HYAMNMAIL From) // FlagsToSetRemove- ...to set/remove these flags (see mode) // mode- nonzero to set, else remove -void WINAPI SetRemoveFlagsInQueueFcn(HYAMNMAIL From, uint32_t FlagsSet, uint32_t FlagsNotSet, uint32_t FlagsToSetRemove, int mode) +void SetRemoveFlagsInQueueFcn(HYAMNMAIL From, uint32_t FlagsSet, uint32_t FlagsNotSet, uint32_t FlagsToSetRemove, int mode) { HYAMNMAIL msgq; diff --git a/protocols/YAMN/src/proto/pop3/pop3comm.cpp b/protocols/YAMN/src/proto/pop3/pop3comm.cpp index c27b27b9bd..761d9a9ffd 100644 --- a/protocols/YAMN/src/proto/pop3/pop3comm.cpp +++ b/protocols/YAMN/src/proto/pop3/pop3comm.cpp @@ -32,9 +32,6 @@ int RegisterPOP3Plugin(WPARAM, LPARAM); // Unloads all variables created on heap (delete[]) DWORD WINAPI UnLoadPOP3(void *); -// Function writes POP3 accounts using YAMN exported functions -DWORD WINAPI WritePOP3Accounts(); - // Function stores plugin's data for account to file DWORD WINAPI WritePOP3Options(HANDLE, CAccount *); @@ -257,7 +254,8 @@ DWORD WINAPI UnLoadPOP3(void *) return 1; } -DWORD WritePOP3Accounts() +// Function writes POP3 accounts using YAMN exported functions +DWORD WINAPI WritePOP3Accounts() { uint32_t ReturnValue = WriteAccountsToFile(POP3Plugin, wszFileName); if (ReturnValue == EACC_SYSTEM) { diff --git a/protocols/YAMN/src/protoplugin.cpp b/protocols/YAMN/src/protoplugin.cpp index 26479e292e..0beaee7a42 100644 --- a/protocols/YAMN/src/protoplugin.cpp +++ b/protocols/YAMN/src/protoplugin.cpp @@ -32,7 +32,7 @@ YAMN_PROTOPLUGIN* RegisterProtocolPlugin(YAMN_PROTOREGISTRATION *Registration) // YAMNMailFcn- pointer to imported functions with mails // returns nonzero if success -int WINAPI SetProtocolPluginFcnImportFcn(YAMN_PROTOPLUGIN *Plugin, YAMN_PROTOIMPORTFCN *YAMNFcn, YAMN_MAILIMPORTFCN *YAMNMailFcn) +int SetProtocolPluginFcnImportFcn(YAMN_PROTOPLUGIN *Plugin, YAMN_PROTOIMPORTFCN *YAMNFcn, YAMN_MAILIMPORTFCN *YAMNMailFcn) { if (YAMNFcn == nullptr) return 0; diff --git a/protocols/YAMN/src/stdafx.h b/protocols/YAMN/src/stdafx.h index ab27af87ee..dc0d91f366 100644 --- a/protocols/YAMN/src/stdafx.h +++ b/protocols/YAMN/src/stdafx.h @@ -99,7 +99,7 @@ uint32_t WriteStringToFile(HANDLE File, char *Source); uint32_t WriteStringToFileW(HANDLE File, wchar_t *Source); DWORD WriteMessagesToFile(HANDLE File, CAccount *Which); -DWORD WritePOP3Accounts(); +DWORD WINAPI WritePOP3Accounts(); void __cdecl DeleteAccountInBackground(void *Which); int StopAccounts(YAMN_PROTOPLUGIN *Plugin); -- cgit v1.2.3