diff options
author | aunsane <aunsane@gmail.com> | 2018-04-21 20:45:34 +0300 |
---|---|---|
committer | aunsane <aunsane@gmail.com> | 2018-04-21 20:45:53 +0300 |
commit | a74debb40c3df12738c722548c556a97e5976036 (patch) | |
tree | f3c2e224d75b64de547778625122d6242e558f36 /plugins/CloudFile/src/http_request.h | |
parent | 803e7b0b5e7c84a814601141fcb7634516eefa30 (diff) |
CloudFile:
- fix #1278
- decrease volume of response data with fields filtering
- fix uploading for gdrive and onedrive in some cases
- simplifying upload code
- version bump
Diffstat (limited to 'plugins/CloudFile/src/http_request.h')
-rw-r--r-- | plugins/CloudFile/src/http_request.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/plugins/CloudFile/src/http_request.h b/plugins/CloudFile/src/http_request.h index d49c225013..db052604b8 100644 --- a/plugins/CloudFile/src/http_request.h +++ b/plugins/CloudFile/src/http_request.h @@ -117,6 +117,18 @@ protected: va_end(urlArgs); } + void AddUrlParameterWithEncode(const char *name, const char *valueFormat, ...) + { + va_list valueArgs; + va_start(valueArgs, valueFormat); + m_szUrl += m_szUrl.Find('?') == -1 ? '?' : '&'; + m_szUrl.AppendFormat("%s=", name); + CMStringA value; + value.AppendFormatV(valueFormat, valueArgs); + m_szUrl.Append(ptrA(mir_urlEncode(value))); + va_end(valueArgs); + } + void SetData(const char *data, size_t size) { if (pData != NULL) |