From 618dfb51d93898632830f1b87443d3f748780871 Mon Sep 17 00:00:00 2001 From: Daniel Wilhelm Date: Fri, 18 Apr 2014 17:05:53 +0200 Subject: 3.5 --- shared/recycler.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'shared/recycler.cpp') diff --git a/shared/recycler.cpp b/shared/recycler.cpp index 4b5a4639..438db680 100644 --- a/shared/recycler.cpp +++ b/shared/recycler.cpp @@ -123,6 +123,7 @@ void moveToWindowsRecycler(const std::vector& filesToDelete) //throw ( { //#warning moving long file paths to recycler does not work! clarify! //filenameDoubleNull += removeLongPathPrefix(*i); //::SHFileOperation() can't handle \\?\-prefix! + //You should use fully-qualified path names with this function. Using it with relative path names is not thread safe. filenameDoubleNull += *i; //::SHFileOperation() can't handle \\?\-prefix! filenameDoubleNull += DefaultChar(0); } @@ -164,7 +165,7 @@ void FreeFileSync::moveToRecycleBin(const Zstring& fileToDelete) //throw (FileE return; //neither file nor any other object with that name existing: no error situation, manual deletion relies on it! #ifdef RECYCLER_GIO - boost::shared_ptr fileObj(g_file_new_for_path(fileToDelete.c_str()), &g_object_unref); + boost::shared_ptr fileObj(g_file_new_for_path(fileToDelete.c_str()), &g_object_unref); //g_file_new_for_path never fails => g_object_unref can always be safely called GError* error = NULL; if (g_file_trash(fileObj.get(), NULL, &error) == FALSE) { @@ -199,8 +200,7 @@ bool FreeFileSync::recycleBinExists() #elif defined RECYCLER_NONE return false; #else -you have to choose a recycler! + you have to choose a recycler! #endif - #endif } -- cgit