debug unload

This commit is contained in:
2025-03-14 22:21:04 -05:00
parent 0807a1e01b
commit 1e3758b0e4
2 changed files with 5 additions and 1 deletions

View File

@@ -12,5 +12,5 @@ void Print::run() {
std::cout << "Print lib loaded and run!\n";
app.unload(self);
//app.end();
std::cout << "App::Get() called\n";
std::cout << "app.unload() called\n";
}

View File

@@ -76,9 +76,13 @@ void App::load(std::string lib) {
void App::unload(decltype(Module::self) it) {
void* handle = (*it)->getHandle();
std::cout << "retrieved handle\nAttempting to delete module: " << (*it)->getName() << std::endl;
delete *it;
std::cout << "deleted module\n";
dlclose(handle);
std::cout << "closed handle\n";
modules.erase(it);
std::cout << "erased iterator\n";
}
void App::handleArgs(const int& argc, char* argv[]) {