diff options
author | George Hazan <ghazan@miranda.im> | 2019-01-29 19:30:08 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2019-01-29 19:30:08 +0300 |
commit | 586459d5ea483af365f7fc5293497bb188c71533 (patch) | |
tree | d23ab339f8fd6f013808127863a6486205adfaef /protocols/ICQ-WIM/src/proto.cpp | |
parent | f3171017912e0d2d375447d19a786d55302ec3e7 (diff) |
ICQ-WIN: fix for file transfers in 32-bit mode
Diffstat (limited to 'protocols/ICQ-WIM/src/proto.cpp')
-rw-r--r-- | protocols/ICQ-WIM/src/proto.cpp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/protocols/ICQ-WIM/src/proto.cpp b/protocols/ICQ-WIM/src/proto.cpp index 5a87f0af89..6de8c1e60d 100644 --- a/protocols/ICQ-WIM/src/proto.cpp +++ b/protocols/ICQ-WIM/src/proto.cpp @@ -370,14 +370,8 @@ HANDLE CIcqProto::SendFile(MCONTACT hContact, const wchar_t*, wchar_t **ppszFile pTransfer->pfts.currentFileSize = pTransfer->pfts.totalBytes = statbuf.st_size; pTransfer->m_fileId = iFileId; - wchar_t *pwszFileName = wcsrchr(ppszFiles[0], '\\'); - if (pwszFileName != nullptr) - pwszFileName++; - else - pwszFileName = ppszFiles[0]; - auto *pReq = new AsyncHttpRequest(CONN_NONE, REQUEST_GET, "https://files.icq.com/files/init", &CIcqProto::OnFileInit); - pReq << CHAR_PARAM("a", m_szAToken) << CHAR_PARAM("client", "icq") << CHAR_PARAM("f", "json") << CHAR_PARAM("fileName", mir_urlEncode(T2Utf(pwszFileName))) + pReq << CHAR_PARAM("a", m_szAToken) << CHAR_PARAM("client", "icq") << CHAR_PARAM("f", "json") << CHAR_PARAM("fileName", mir_urlEncode(T2Utf(pTransfer->m_wszShortName))) << CHAR_PARAM("k", ICQ_APP_ID) << INT_PARAM("size", statbuf.st_size) << INT_PARAM("ts", time(0)); CalcHash(pReq); pReq->pUserInfo = pTransfer; |