MCPcopy Create free account
hub / github.com/armory3d/armory / sys_command

Function sys_command

armorcore/Sources/main.cpp:2103–2114  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2101 }
2102
2103 int sys_command(const char *cmd) {
2104 #ifdef KORE_WINDOWS
2105 int wlen = MultiByteToWideChar(CP_UTF8, 0, cmd, -1, NULL, 0);
2106 wchar_t *wstr = new wchar_t[wlen];
2107 MultiByteToWideChar(CP_UTF8, 0, cmd, -1, wstr, wlen);
2108 int result = _wsystem(wstr);
2109 delete[] wstr;
2110 #else
2111 int result = system(cmd);
2112 #endif
2113 return result;
2114 }
2115
2116 void krom_sys_command(const FunctionCallbackInfo<Value> &args) {
2117 HandleScope scope(args.GetIsolate());

Callers 2

krom_sys_commandFunction · 0.85
krom_delete_fileFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected