summaryrefslogtreecommitdiff
path: root/protocols
diff options
context:
space:
mode:
authorRobert Pösel <robyer@seznam.cz>2016-03-25 23:22:02 +0000
committerRobert Pösel <robyer@seznam.cz>2016-03-25 23:22:02 +0000
commit6a47baae2e0b0e0e2658b5e758901d25bd0cf488 (patch)
treeaa3f4501aea8ba1a53a461f9b0d19fe8b69d7c80 /protocols
parent47b775f2742d0d3649359bd6537979fba7486d7e (diff)
Facebook: Don't try to parse attachments when there is none
git-svn-id: http://svn.miranda-ng.org/main/trunk@16545 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols')
-rw-r--r--protocols/FacebookRM/src/json.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/protocols/FacebookRM/src/json.cpp b/protocols/FacebookRM/src/json.cpp
index d6aaa91de5..9cbfdcb5f7 100644
--- a/protocols/FacebookRM/src/json.cpp
+++ b/protocols/FacebookRM/src/json.cpp
@@ -391,6 +391,9 @@ void parseAttachments2(FacebookProto *proto, std::string *message_text, const JS
const JSONNode &attach_ = it["attachments"]["mercury"];
+ if (!attach_)
+ return;
+
/* const JSONNode &attachments = it["attachments"];
for (auto itAttachment = attachments.begin(); itAttachment != attachments.end(); ++itAttachment) {
const JSONNode &attach_ = (*itAttachment)["mercury"];*/