Skip to content

Commit

Permalink
Add call SetDefaultDllDirectories()
Browse files Browse the repository at this point in the history
  • Loading branch information
0xbadfca11 committed Aug 5, 2017
1 parent d3283b9 commit a3ef1b5
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions fat32format.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -651,6 +651,11 @@ void usage(void)

int main(int argc, char* argv[])
{
if (PVOID SetDefaultDllDirectoriesPtr = GetProcAddress(GetModuleHandleW(L"kernel32"), "SetDefaultDllDirectories"))
{
static_cast<decltype(SetDefaultDllDirectories)*>(SetDefaultDllDirectoriesPtr)(LOAD_LIBRARY_SEARCH_SYSTEM32);
}

if (argc < 2)
{
usage();
Expand Down

0 comments on commit a3ef1b5

Please sign in to comment.