summaryrefslogtreecommitdiff
path: root/src/net/CurlHttpClient.cpp
diff options
context:
space:
mode:
authorjellybrick <shlee1503@naver.com>2020-03-14 23:21:30 +0900
committerjellybrick <shlee1503@naver.com>2020-03-14 23:21:42 +0900
commit64174491dac84c559db5c48ed850177fa3eb4da0 (patch)
tree5f7a754d57c2a7ec439f309df5e4b8d964d0834f /src/net/CurlHttpClient.cpp
parent19f49b7a2f540a756ed9759b0fa5fb52bf73f20e (diff)
Fix #127, #128 & Code quality improvements
It seems that the author of this code misunderstood 'Array of PollOption' as 'PollOption'.
Diffstat (limited to 'src/net/CurlHttpClient.cpp')
-rw-r--r--src/net/CurlHttpClient.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/net/CurlHttpClient.cpp b/src/net/CurlHttpClient.cpp
index 5bd9313..6255974 100644
--- a/src/net/CurlHttpClient.cpp
+++ b/src/net/CurlHttpClient.cpp
@@ -17,9 +17,9 @@ CurlHttpClient::~CurlHttpClient() {
}
static std::size_t curlWriteString(char* ptr, std::size_t size, std::size_t nmemb, void* userdata) {
- static_cast<std::string *>(userdata)->append(ptr, size * nmemb);
+ static_cast<std::string*>(userdata)->append(ptr, size * nmemb);
return size * nmemb;
-};
+}
std::string CurlHttpClient::makeRequest(const Url& url, const std::vector<HttpReqArg>& args) const {
// Copy settings for each call because we change CURLOPT_URL and other stuff.
@@ -34,8 +34,8 @@ std::string CurlHttpClient::makeRequest(const Url& url, const std::vector<HttpRe
headers = curl_slist_append(headers, "Connection: close");
curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers);
- curl_mime *mime;
- curl_mimepart *part;
+ curl_mime* mime;
+ curl_mimepart* part;
mime = curl_mime_init(curl);
if (!args.empty()) {
for (const HttpReqArg& a : args) {