Fix library loading

This commit is contained in:
momo5502 2022-09-18 11:47:12 +02:00
parent cae5347c0c
commit 2822088800
2 changed files with 7 additions and 1 deletions

View File

@ -2,9 +2,14 @@
namespace utils::nt
{
library library::load(const char* name)
{
return library(LoadLibraryA(name));
}
library library::load(const std::string& name)
{
return library(LoadLibraryA(name.data()));
return library::load(name.data());
}
library library::load(const std::filesystem::path& path)

View File

@ -21,6 +21,7 @@ namespace utils::nt
class library final
{
public:
static library load(const char* name);
static library load(const std::string& name);
static library load(const std::filesystem::path& path);
static library get_by_address(const void* address);