[ #4786 ] if space in the Application path name, system() doesn't work on some platforms
[blender.git] / source / blender / src / buttons_scene.c
index 0ab4b4b75f939cff6c73c83ad80b85bf08bff7b4..1711ec7d4fb921e1c87fadc73525c0c21775c090 100644 (file)
@@ -505,8 +505,11 @@ static void run_playanim(char *file)
        /* use current settings for defining position of window. it actually should test image size */
        calc_renderwin_rectangle((G.scene->r.xsch*G.scene->r.size)/100, 
                                                         (G.scene->r.ysch*G.scene->r.size)/100, G.winpos, pos, size);
-
+#ifdef WIN32
        sprintf(str, "%s -a -p %d %d \"%s\"", bprogname, pos[0], pos[1], file);
+#else
+       sprintf(str, "\"%s\" -a -p %d %d \"%s\"", bprogname, pos[0], pos[1], file);
+#endif
        system(str);
 }