MCPcopy Create free account
hub / github.com/ObEngine/ObEngine / open

Method open

extlibs/dynamicLinker/src/dynamicLinker.cpp:37–51  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

35 }
36
37 bool dynamicLinker::open() {
38 // C++14:
39 // lib = std::make_unique<_void>( dlopen( libPath.c_str(), RTLD_NOW | RTLD_LOCAL ) );
40 auto v = new _void( openLib() );
41 lib = std::unique_ptr<_void>( v );
42
43 if ( lib->ptr() == nullptr ) {
44 lib = nullptr;
45 char* err = nullptr;
46 std::string s = (err == nullptr) ? "FATAL ERROR: no error!" : std::string(err);
47 throw openException(s);
48 }
49
50 return true;
51 }
52
53 dynamicLinker::~dynamicLinker() {
54 if( lib != nullptr ) {

Callers

nothing calls this directly

Calls 3

openExceptionClass · 0.85
ptrMethod · 0.80
stringClass · 0.50

Tested by

no test coverage detected