diff --git a/rtgui/batchqueue.cc b/rtgui/batchqueue.cc index 554602adf..d6cd5ab32 100644 --- a/rtgui/batchqueue.cc +++ b/rtgui/batchqueue.cc @@ -351,12 +351,13 @@ Glib::ustring BatchQueue::autoCompleteFileName (const Glib::ustring& fileName, c int fileExists=Glib::file_test (fname, Glib::FILE_TEST_EXISTS); - /*if (inOverwriteMode && fileExists) { - if (g_remove(safe_locale_from_utf8(fname).c_str ()) == -1) + if (inOverwriteMode && fileExists) { + // do NOT use g_remove as it has compiler problems on Unix and OSX (GTK namespace problem) + if (::remove(safe_locale_from_utf8(fname).c_str ()) == -1) inOverwriteMode = false; // failed to delete- revert to old naming scheme else fileExists = false; // deleted now - }*/ + } if (!fileExists) { return fname;