check dlerror
This commit is contained in:
@@ -85,12 +85,13 @@ void App::unload(decltype(Module::self) it) {
|
||||
std::cout << "retrieved handle\nAttempting to delete module: " << (*it)->getName() << std::endl;
|
||||
delete *it;
|
||||
std::cout << "deleted module\n";
|
||||
if(h) {
|
||||
char* mesg = dlerror();
|
||||
if(h && !mesg) {
|
||||
std::cout << "h: " << h << " attempting to dlclose\n";
|
||||
dlclose(h);
|
||||
std::cout << "closed handle\n";
|
||||
} else {
|
||||
std::cout << "Why no h?\n";
|
||||
std::cout << "error: " << mesg << "\n";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user