chg, clean up
This commit is contained in:
@@ -264,7 +264,6 @@ static int CmdScriptRun(const char *Cmd) {
|
|||||||
|
|
||||||
For apt-cyg (Cygwin...):
|
For apt-cyg (Cygwin...):
|
||||||
apt-cyg install python3-devel # for python3.x installs
|
apt-cyg install python3-devel # for python3.x installs
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef HAVE_PYTHON
|
#ifdef HAVE_PYTHON
|
||||||
@@ -288,7 +287,6 @@ static int CmdScriptRun(const char *Cmd) {
|
|||||||
//int argc, char ** argv
|
//int argc, char ** argv
|
||||||
char *argv[128];
|
char *argv[128];
|
||||||
int argc = split(arguments, argv);
|
int argc = split(arguments, argv);
|
||||||
|
|
||||||
wchar_t *py_args[argc];
|
wchar_t *py_args[argc];
|
||||||
py_args[0] = Py_DecodeLocale(preferredName, NULL);
|
py_args[0] = Py_DecodeLocale(preferredName, NULL);
|
||||||
for (int i = 0; i < argc; i++) {
|
for (int i = 0; i < argc; i++) {
|
||||||
@@ -312,12 +310,8 @@ static int CmdScriptRun(const char *Cmd) {
|
|||||||
return PM3_ESOFT;
|
return PM3_ESOFT;
|
||||||
}
|
}
|
||||||
|
|
||||||
// to we need to manually call all importmodules?
|
|
||||||
//PyImport_ImportModule("requests");
|
|
||||||
PyRun_SimpleFileExFlags(f, preferredName, 1, NULL);
|
PyRun_SimpleFileExFlags(f, preferredName, 1, NULL);
|
||||||
|
|
||||||
Py_Finalize();
|
Py_Finalize();
|
||||||
|
|
||||||
PyMem_RawFree(program);
|
PyMem_RawFree(program);
|
||||||
free(script_path);
|
free(script_path);
|
||||||
PrintAndLogEx(SUCCESS, "\nfinished " _YELLOW_("%s"), preferredName);
|
PrintAndLogEx(SUCCESS, "\nfinished " _YELLOW_("%s"), preferredName);
|
||||||
|
|||||||
Reference in New Issue
Block a user