MCPcopy Create free account
hub / github.com/ArduPilot/ardupilot / findfile

Function findfile

libraries/AP_Scripting/lua/src/loadlib.c:477–486  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

475
476
477static const char *findfile (lua_State *L, const char *name,
478 const char *pname,
479 const char *dirsep) {
480 const char *path;
481 lua_getfield(L, lua_upvalueindex(1), pname);
482 path = lua_tostring(L, -1);
483 if (path == NULL)
484 luaL_error(L, "'package.%s' must be a string", pname);
485 return searchpath(L, name, path, ".", dirsep);
486}
487
488
489static int checkload (lua_State *L, int stat, const char *filename) {

Callers 3

searcher_LuaFunction · 0.85
searcher_CFunction · 0.85
searcher_CrootFunction · 0.85

Calls 3

lua_getfieldFunction · 0.85
luaL_errorFunction · 0.85
searchpathFunction · 0.85

Tested by

no test coverage detected