forked from metin2/client
Removed Armadillo Nanomite
This commit is contained in:
@ -114,7 +114,6 @@ void CPythonLauncher::SetTraceFunc(int (*pFunc)(PyObject * obj, PyFrameObject *
|
||||
|
||||
bool CPythonLauncher::Create(const char* c_szProgramName)
|
||||
{
|
||||
NANOBEGIN
|
||||
Py_SetProgramName((char*)c_szProgramName);
|
||||
#ifdef _DEBUG
|
||||
PyEval_SetTrace(TraceFunc, NULL);
|
||||
@ -138,13 +137,11 @@ bool CPythonLauncher::Create(const char* c_szProgramName)
|
||||
if (!RunLine("import sys"))
|
||||
return false;
|
||||
|
||||
NANOEND
|
||||
return true;
|
||||
}
|
||||
|
||||
bool CPythonLauncher::RunCompiledFile(const char* c_szFileName)
|
||||
{
|
||||
NANOBEGIN
|
||||
FILE * fp = fopen(c_szFileName, "rb");
|
||||
|
||||
if (!fp)
|
||||
@ -191,14 +188,12 @@ bool CPythonLauncher::RunCompiledFile(const char* c_szFileName)
|
||||
if (Py_FlushLine())
|
||||
PyErr_Clear();
|
||||
|
||||
NANOEND
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
bool CPythonLauncher::RunMemoryTextFile(const char* c_szFileName, std::shared_ptr<std::vector<char>> fileData)
|
||||
{
|
||||
NANOBEGIN
|
||||
std::string stConvFileData;
|
||||
stConvFileData.reserve(fileData->size());
|
||||
stConvFileData+="exec(compile('''";
|
||||
@ -219,7 +214,6 @@ bool CPythonLauncher::RunMemoryTextFile(const char* c_szFileName, std::shared_pt
|
||||
stConvFileData+= "'exec'))";
|
||||
|
||||
const CHAR* c_pcConvFileData=stConvFileData.c_str();
|
||||
NANOEND
|
||||
return RunLine(c_pcConvFileData);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user