Updating branch refs/heads/master
         to beee35a7487f94472a058f9d5904aff7766bff7e (commit)
       from 2d3c09adcd9b523a48a498facd0e35b04ca8acc5 (commit)

commit beee35a7487f94472a058f9d5904aff7766bff7e
Author: Nick Schermer <[email protected]>
Date:   Mon Dec 27 20:44:42 2010 +0100

    Quote filenames with a space in the desktop editor (bug #6951).

 exo-desktop-item-edit/exo-die-command-entry.c |    9 +++++++++
 1 files changed, 9 insertions(+), 0 deletions(-)

diff --git a/exo-desktop-item-edit/exo-die-command-entry.c 
b/exo-desktop-item-edit/exo-die-command-entry.c
index f0dd9c8..85893b2 100644
--- a/exo-desktop-item-edit/exo-die-command-entry.c
+++ b/exo-desktop-item-edit/exo-die-command-entry.c
@@ -357,6 +357,15 @@ exo_die_command_entry_button_clicked (GtkWidget          
*button,
           filename = s;
         }
 
+      /* quote the filename if it contains a space */
+      if (filename != NULL
+          && strchr (filename, ' ') != NULL)
+        {
+          s = g_shell_quote (filename);
+          g_free (filename);
+          filename = s;
+        }
+
       /* apply the new command */
       exo_die_command_entry_set_text (command_entry, filename);
       g_free (filename);
_______________________________________________
Xfce4-commits mailing list
[email protected]
http://foo-projects.org/mailman/listinfo/xfce4-commits

Reply via email to