MCPcopy Create free account
hub / github.com/defold/defold / dmEngineGetResult

Function dmEngineGetResult

engine/engine/src/engine.cpp:2642–2662  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2640}
2641
2642void dmEngineGetResult(dmEngine::HEngine engine, int* run_action, int* exit_code, int* argc, char*** argv)
2643{
2644 if (run_action)
2645 *run_action = (int)GetAppResultFromAction(engine->m_RunResult.m_Action);
2646 if (exit_code)
2647 *exit_code = engine->m_RunResult.m_ExitCode;
2648
2649 int _argc = engine->m_RunResult.m_Argc;
2650 if (argc)
2651 *argc = _argc;
2652
2653 if (argv)
2654 {
2655 *argv = (char**)malloc(sizeof(char*) * _argc);
2656
2657 for (int i = 0; i < _argc; ++i)
2658 {
2659 (*argv)[i] = strdup(engine->m_RunResult.m_Argv[i]);
2660 }
2661 }
2662}

Callers 1

TestEngineGetResultFunction · 0.85

Calls 2

GetAppResultFromActionFunction · 0.85
mallocFunction · 0.85

Tested by 1

TestEngineGetResultFunction · 0.68