i'm passing an LPSTR to a c++ dll function call from a c++ exe application. but i'm getting an exception thrown when i try to do this. here is my code:
LPSTR sInstalledProducts;
int* dummy;
typedef int (__stdcall FUNCPROC)(HWND, LPSTR, int*);
HINSTANCE hInstance;
FUNCPROC* pFunction;
VERIFY(hInstance = ::LoadLibrary(sSysDir));
VERIFY(pFunction = (FUNCPROC*)::GetProcAddress(hInstance, "Find_Installed_Products"
);
int i = (*pFunction)(this->GetSafeHwnd(), sInstalledProducts, dummy);
What am I doing wrong? My problem has something to do with sInstalledProducts.
LPSTR sInstalledProducts;
int* dummy;
typedef int (__stdcall FUNCPROC)(HWND, LPSTR, int*);
HINSTANCE hInstance;
FUNCPROC* pFunction;
VERIFY(hInstance = ::LoadLibrary(sSysDir));
VERIFY(pFunction = (FUNCPROC*)::GetProcAddress(hInstance, "Find_Installed_Products"
int i = (*pFunction)(this->GetSafeHwnd(), sInstalledProducts, dummy);
What am I doing wrong? My problem has something to do with sInstalledProducts.