about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--src/client.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/client.cpp b/src/client.cpp index 1938af4..26f3289 100644 --- a/src/client.cpp +++ b/src/client.cpp
@@ -131,7 +131,8 @@ namespace twitter {
131 curl::curl_pair<CURLformoption, std::string> command_name(CURLFORM_COPYNAME, "command"); 131 curl::curl_pair<CURLformoption, std::string> command_name(CURLFORM_COPYNAME, "command");
132 curl::curl_pair<CURLformoption, std::string> command_cont(CURLFORM_COPYCONTENTS, "INIT"); 132 curl::curl_pair<CURLformoption, std::string> command_cont(CURLFORM_COPYCONTENTS, "INIT");
133 curl::curl_pair<CURLformoption, std::string> bytes_name(CURLFORM_COPYNAME, "total_bytes"); 133 curl::curl_pair<CURLformoption, std::string> bytes_name(CURLFORM_COPYNAME, "total_bytes");
134 curl::curl_pair<CURLformoption, std::string> bytes_cont(CURLFORM_COPYCONTENTS, std::to_string(data_length)); 134 std::string str_data_length = std::to_string(data_length);
135 curl::curl_pair<CURLformoption, std::string> bytes_cont(CURLFORM_COPYCONTENTS, str_data_length);
135 curl::curl_pair<CURLformoption, std::string> type_name(CURLFORM_COPYNAME, "media_type"); 136 curl::curl_pair<CURLformoption, std::string> type_name(CURLFORM_COPYNAME, "media_type");
136 curl::curl_pair<CURLformoption, std::string> type_cont(CURLFORM_COPYCONTENTS, media_type); 137 curl::curl_pair<CURLformoption, std::string> type_cont(CURLFORM_COPYCONTENTS, media_type);
137 form.add(command_name, command_cont); 138 form.add(command_name, command_cont);
@@ -181,7 +182,8 @@ namespace twitter {
181 curl::curl_pair<CURLformoption, std::string> command3_name(CURLFORM_COPYNAME, "command"); 182 curl::curl_pair<CURLformoption, std::string> command3_name(CURLFORM_COPYNAME, "command");
182 curl::curl_pair<CURLformoption, std::string> command3_cont(CURLFORM_COPYCONTENTS, "FINALIZE"); 183 curl::curl_pair<CURLformoption, std::string> command3_cont(CURLFORM_COPYCONTENTS, "FINALIZE");
183 curl::curl_pair<CURLformoption, std::string> media_id_name(CURLFORM_COPYNAME, "media_id"); 184 curl::curl_pair<CURLformoption, std::string> media_id_name(CURLFORM_COPYNAME, "media_id");
184 curl::curl_pair<CURLformoption, std::string> media_id_cont(CURLFORM_COPYCONTENTS, std::to_string(media_id)); 185 std::string str_media_id = std::to_string(media_id);
186 curl::curl_pair<CURLformoption, std::string> media_id_cont(CURLFORM_COPYCONTENTS, str_media_id);
185 finalize_form.add(command3_name, command3_cont); 187 finalize_form.add(command3_name, command3_cont);
186 finalize_form.add(media_id_name, media_id_cont); 188 finalize_form.add(media_id_name, media_id_cont);
187 189