Comment 144 for bug 1512120

Revision history for this message
In , Rocketx86 (rocketx86) wrote :

After quite a bit of debugging and testing I have produced the following rename patch for Thunar.

--- Thunar-1.6.10/thunar/thunar-io-jobs.c 2015-05-22 13:25:36.000000000 +0000
+++ Thunar-1.6.10-fix/thunar/thunar-io-jobs.c 2016-08-01 11:07:09.016666668 +0000
@@ -1307,7 +1307,12 @@
 {
   _thunar_return_val_if_fail (THUNAR_IS_FILE (file), NULL);
   _thunar_return_val_if_fail (g_utf8_validate (display_name, -1, NULL), NULL);
-
+
+ if (!THUNAR_IS_FILE (file))
+ {
+ return NULL;
+ }
+
   return thunar_simple_job_launch (_thunar_io_jobs_rename, 2,
                                    THUNAR_TYPE_FILE, file,
                                    G_TYPE_STRING, display_name);