[ #4786 ] if space in the Application path name, system() doesn't work on some platforms
[blender.git] / source / blender / src / editimasel.c
index 3d2b3c8b715ea6aac3b6bb4b52ced03221370cdd..f3f9aa31d07abe2431c2fae045da080d92631dfa 100644 (file)
@@ -340,8 +340,11 @@ void winqreadimaselspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
        case PKEY:
                if(G.qual & LR_SHIFTKEY) {
                        extern char bprogname[];        /* usiblender.c */
-                       
+#ifdef WIN32                   
                        sprintf(name, "%s -a \"%s%s\"", bprogname, simasel->dir, simasel->file);
+#else
+                       sprintf(name, "\"%s\" -a \"%s%s\"", bprogname, simasel->dir, simasel->file);
+#endif
                        system(name);
                }
                if(G.qual & LR_CTRLKEY) {