summaryrefslogtreecommitdiffstats
path: root/qthelper.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'qthelper.cpp')
-rw-r--r--qthelper.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/qthelper.cpp b/qthelper.cpp
index c316481f2..31ec43df7 100644
--- a/qthelper.cpp
+++ b/qthelper.cpp
@@ -644,7 +644,12 @@ extern "C" char *move_away(const char *old_path)
if (!oldDir.rename(old_path, newPath)) {
if (verbose)
qDebug() << "rename of" << old_path << "to" << newPath << "failed";
- return strdup("");
+ // this next one we only try on Windows... if we are on a different platform
+ // we simply give up and return an empty string
+#ifdef WIN32
+ if (subsurface_dir_rename(old_path, qPrintable(newPath)) == 0)
+#endif
+ return strdup("");
}
return strdup(qPrintable(newPath));
}