diff options
author | George Hazan <george.hazan@gmail.com> | 2024-04-07 20:18:35 +0300 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2024-04-07 20:18:39 +0300 |
commit | 87e7faeba43caf78eb9f5b08350e1fd07268d7cd (patch) | |
tree | f17940f599553ea675db1b730d43de6bac9168bf /protocols/CloudFile/src | |
parent | cd6fcef67cdf3c72afc98ed149f82af7f6860487 (diff) |
fixes #4335 (Cloudfile Upload not working)
Diffstat (limited to 'protocols/CloudFile/src')
-rw-r--r-- | protocols/CloudFile/src/Services/yandex_service.cpp | 9 | ||||
-rw-r--r-- | protocols/CloudFile/src/http_request.h | 2 |
2 files changed, 4 insertions, 7 deletions
diff --git a/protocols/CloudFile/src/Services/yandex_service.cpp b/protocols/CloudFile/src/Services/yandex_service.cpp index 892821e0c4..e252eed161 100644 --- a/protocols/CloudFile/src/Services/yandex_service.cpp +++ b/protocols/CloudFile/src/Services/yandex_service.cpp @@ -102,11 +102,10 @@ void CYandexService::RequestAccessTokenThread(void *param) NLHR_PTR response(request.Send(m_hConnection)); if (response == nullptr || response->resultCode != HTTP_CODE_OK) { - const char *error = response->body.GetLength() - ? response->body - : HttpStatusToError(response->resultCode); - - Netlib_Logf(m_hConnection, "%s: %s", GetAccountName(), error); + if (response) { + const char *error = response->body.GetLength() ? response->body : HttpStatusToError(response->resultCode); + Netlib_Logf(m_hConnection, "%s: %s", GetAccountName(), error); + } ShowNotification(TranslateT("Server does not respond"), MB_ICONERROR); EndDialog(hwndDlg, 0); return; diff --git a/protocols/CloudFile/src/http_request.h b/protocols/CloudFile/src/http_request.h index c9921cfd76..bcda0e1c3e 100644 --- a/protocols/CloudFile/src/http_request.h +++ b/protocols/CloudFile/src/http_request.h @@ -20,8 +20,6 @@ public: class HttpRequest : public MHttpRequest { private: - CMStringA m_szUrl; - void Init() { flags = NLHRF_HTTP11 | NLHRF_SSL | NLHRF_NODUMP; |