From b303e45693776387a11d4fc2735640a1b78dda66 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Mon, 19 Aug 2024 15:15:20 +0300 Subject: =?UTF-8?q?fixes=20#4574=20(Skypeweb:=20=D1=81=D1=82=D1=80=D0=B0?= =?UTF-8?q?=D0=BD=D0=BD=D0=BE=D0=B5=20=D0=BF=D0=BE=D0=B2=D0=B5=D0=B4=D0=B5?= =?UTF-8?q?=D0=BD=D0=B8=D0=B5=20=D0=BE=D1=84=D1=84=D0=BB=D0=B0=D0=B9=D0=BD?= =?UTF-8?q?-=D1=84=D0=B0=D0=B9=D0=BB=D0=B0=20(=D0=BA=D0=B0=D1=80=D1=82?= =?UTF-8?q?=D0=B8=D0=BD=D0=BA=D0=B8))?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- protocols/SkypeWeb/src/skype_files.cpp | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'protocols/SkypeWeb/src/skype_files.cpp') diff --git a/protocols/SkypeWeb/src/skype_files.cpp b/protocols/SkypeWeb/src/skype_files.cpp index ee9ace0407..e7cb709898 100644 --- a/protocols/SkypeWeb/src/skype_files.cpp +++ b/protocols/SkypeWeb/src/skype_files.cpp @@ -27,10 +27,10 @@ void CSkypeProto::ReceiveFileThread(void *param) else { CMStringA szCookie, szUrl; szCookie.AppendFormat("skypetoken_asm=%s", m_szApiToken.get()); + + auto &json = dbei.getJson(); + auto skft = json["skft"].as_string(); { - auto &json = dbei.getJson(); - auto skft = json["skft"].as_string(); - const char *preview; if (skft == "Picture.1") preview = "imgpsh_mobile_save_anim"; @@ -60,7 +60,14 @@ void CSkypeProto::ReceiveFileThread(void *param) if (!szUrl.IsEmpty()) { MHttpRequest nlhr(REQUEST_GET); nlhr.flags = NLHRF_HTTP11 | NLHRF_NOUSERAGENT; - nlhr.m_szUrl = szUrl; + nlhr.m_szUrl = blob.getUrl(); + if (skft == "Picture.1") + nlhr.m_szUrl += "/views/imgpsh_fullsize_anim"; + else if (skft == "Video.1") + nlhr.m_szUrl += "/views/video"; + else + nlhr.m_szUrl += "/views/original"; + nlhr.AddHeader("Accept", "*/*"); nlhr.AddHeader("Accept-Encoding", "gzip, deflate"); nlhr.AddHeader("Cookie", szCookie); -- cgit v1.2.3