From 4fd1a5edd57e9f0422c140986668d1fccba4bc82 Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Sat, 19 Apr 2014 02:03:43 +0200 Subject: videotimeline: path related fixes for windows --- gtk2_ardour/utils_videotl.cc | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'gtk2_ardour/utils_videotl.cc') diff --git a/gtk2_ardour/utils_videotl.cc b/gtk2_ardour/utils_videotl.cc index 2e250b2cee..3b5882905b 100644 --- a/gtk2_ardour/utils_videotl.cc +++ b/gtk2_ardour/utils_videotl.cc @@ -151,6 +151,13 @@ VideoUtils::video_map_path (std::string server_docroot, std::string filepath) { std::string rv = filepath; + /* strip docroot */ + if (server_docroot.length() > 0) { + if (rv.compare(0, server_docroot.length(), server_docroot) == 0 ) { + rv = rv.substr(server_docroot.length()); + } + } + /* replace all G_DIR_SEPARATOR with '/' */ size_t look_here = 0; size_t found_here; @@ -159,13 +166,6 @@ VideoUtils::video_map_path (std::string server_docroot, std::string filepath) look_here = found_here + 1; } - /* strip docroot */ - if (server_docroot.length() > 0) { - if (rv.compare(0, server_docroot.length(), server_docroot) == 0 ) { - rv = rv.substr(server_docroot.length()); - } - } - CURL *curl; char *ue; curl = curl_easy_init(); -- cgit v1.2.3