summaryrefslogtreecommitdiff
path: root/protocols/FacebookRM/src/process.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2018-03-02 23:42:36 +0300
committerGeorge Hazan <ghazan@miranda.im>2018-03-02 23:42:36 +0300
commit0e8f5a3aa5f5e73b413c5646444751783e367f2b (patch)
treeca7479a4b239d1c024013bf5a87d3e95c4edb8d8 /protocols/FacebookRM/src/process.cpp
parenta5fb0cc691901e986e25f5a724c0024ff8323957 (diff)
Facebook: unneeded thread removed
Diffstat (limited to 'protocols/FacebookRM/src/process.cpp')
-rw-r--r--protocols/FacebookRM/src/process.cpp34
1 files changed, 1 insertions, 33 deletions
diff --git a/protocols/FacebookRM/src/process.cpp b/protocols/FacebookRM/src/process.cpp
index 4a413b4035..4455126c61 100644
--- a/protocols/FacebookRM/src/process.cpp
+++ b/protocols/FacebookRM/src/process.cpp
@@ -369,7 +369,7 @@ void FacebookProto::LoadHistory(void *pParam)
try {
messages.clear();
- ParseHistory(&resp.data, &messages, &firstTimestamp);
+ ParseHistory(&resp.data, messages, &firstTimestamp);
// Receive messages
std::string previousFirstMessageId = firstMessageId;
@@ -890,38 +890,6 @@ void FacebookProto::ReceiveMessages(std::vector<facebook_message> &messages, boo
delete hChatContacts;
}
-void FacebookProto::ProcessMessages(void* data)
-{
- if (data == nullptr)
- return;
-
- std::string* resp = (std::string*)data;
-
- if (isOffline()) {
- delete resp;
- return;
- }
-
- debugLogA("*** Starting processing messages");
-
- try {
- std::vector<facebook_message> messages;
- ParseMessages(resp, &messages);
-
- ReceiveMessages(messages);
-
- if (getBool(FACEBOOK_KEY_EVENT_NOTIFICATIONS_ENABLE, DEFAULT_EVENT_NOTIFICATIONS_ENABLE))
- ShowNotifications();
-
- debugLogA("*** Messages processed");
- }
- catch (const std::exception &e) {
- debugLogA("*** Error processing messages: %s", e.what());
- }
-
- delete resp;
-}
-
void FacebookProto::ShowNotifications()
{
mir_cslock s(facy.notifications_lock_);