raster pushed a commit to branch master.

http://git.enlightenment.org/apps/terminology.git/commit/?id=48919324444c741726206fe8b4f89bd13bcbe5f2

commit 48919324444c741726206fe8b4f89bd13bcbe5f2
Author: Carsten Haitzler (Rasterman) <ras...@rasterman.com>
Date:   Wed Jan 22 15:44:57 2014 +0900

    fix escaping of file in helper run in 1 missed case
    
    this fixes T814
---
 src/bin/termio.c | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/src/bin/termio.c b/src/bin/termio.c
index 72b5b2b..dbd686e 100644
--- a/src/bin/termio.c
+++ b/src/bin/termio.c
@@ -740,10 +740,15 @@ _smart_media_clicked(void *data, Evas_Object *obj, void 
*info EINA_UNUSED)
                          cmd = config->helper.local.general;
                        if (cmd)
                          {
-                            char buf[PATH_MAX];
+                            char buf[PATH_MAX], *escaped;
                             
-                            snprintf(buf, sizeof(buf), "%s %s", cmd, file);
-                            ecore_exe_run(buf, NULL);
+                            escaped = ecore_file_escape_name(file);
+                            if (escaped)
+                              {
+                                 snprintf(buf, sizeof(buf), "%s %s", cmd, 
escaped);
+                                 ecore_exe_run(buf, NULL);
+                                 free(escaped);
+                              }
                             return;
                          }
                     }

-- 


Reply via email to