summaryrefslogtreecommitdiff
path: root/src/lib/curl_uploader.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2016-04-18 22:15:10 +0100
committerCarl Hetherington <cth@carlh.net>2016-04-18 22:15:10 +0100
commitf71c67d250140c16aaf6d127f86645919435753f (patch)
tree1c4903b5b14cb2d44bcb031dedb4a0bc2e7b6697 /src/lib/curl_uploader.cc
parent52a7ca2de15ad04c04b9fe49151948a2ee894033 (diff)
Use generic_string() in a couple of places to avoid unwanted backslashes in filenames.
Diffstat (limited to 'src/lib/curl_uploader.cc')
-rw-r--r--src/lib/curl_uploader.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lib/curl_uploader.cc b/src/lib/curl_uploader.cc
index 11c389307..48f982482 100644
--- a/src/lib/curl_uploader.cc
+++ b/src/lib/curl_uploader.cc
@@ -76,7 +76,8 @@ CurlUploader::upload_file (boost::filesystem::path from, boost::filesystem::path
{
curl_easy_setopt (
_curl, CURLOPT_URL,
- String::compose ("ftp://%1/%2/%3", Config::instance()->tms_ip(), Config::instance()->tms_path(), to.string ()).c_str ()
+ /* Use generic_string so that we get forward-slashes in the path, even on Windows */
+ String::compose ("ftp://%1/%2/%3", Config::instance()->tms_ip(), Config::instance()->tms_path(), to.generic_string ()).c_str ()
);
_file = fopen_boost (from, "rb");