Salome HOME
Handlling Python scripts without execution permissions
[modules/gui.git] / src / SalomeApp / SalomeApp_Application.cxx
index 3bbe372618f3f29ce77d5d4f1e00db7927fa9e48..165baf94c53effd5b43c95eac7f144b9e89770f2 100644 (file)
@@ -247,6 +247,8 @@ void SalomeApp_Application::start()
               if (!args.isEmpty()) {
                 args = "args:"+args;
               }
+
+              script.remove( QRegExp("^python.*[\\s]+") );
               QString cmd = script+" "+args;
               QString command = QString( "execfile(r\"%1\")" ).arg(cmd.trimmed());
               pyConsole->exec(command);