FreeRDP/winpr/libwinpr/library/test/TestLibraryLoadLibrary.c
2012-10-05 14:45:54 -04:00

29 lines
432 B
C

#include <stdio.h>
#include <winpr/crt.h>
#include <winpr/file.h>
#include <winpr/tchar.h>
#include <winpr/windows.h>
#include <winpr/library.h>
int TestLibraryLoadLibrary(int argc, char* argv[])
{
HINSTANCE library;
library = LoadLibrary(_T("kernel32.dll"));
if (!library)
{
printf("LoadLibrary failure\n");
return -1;
}
if (!FreeLibrary(library))
{
printf("FreeLibrary failure\n");
return -1;
}
return 0;
}