I changed the cefclient2008 project to be Multi-threaded Debug DLL and then followed all the instructions to rebuild the libcef_dll_wrapper.lib and the project builds without any link errors.
However when I run the code I get the follow exception:
Run-Time Check Failure #0 - The value of ESP was not properly saved across a function call.
This is usually a result of calling a function declared with one calling convention with a function pointer
declared with a different calling convention.
This happens in hander_cpptoc.cc in handler_handle_load_start right at the end when it tries to exit.....
Anybody have any ideas where I might have gone wrong?
I do notice that CEF_CALLBACK is defined as __stdcall and that libcef_dll_wrapper is built with __cdecl (/Gd) as is cefclient, could that have anything to do with it?
enum cef_retval_t CEF_CALLBACK handler_handle_load_start(
struct _cef_handler_t* self, cef_browser_t* browser, cef_frame_t* frame,
int isMainContent)
{
DCHECK(self);
DCHECK(browser);
if(!self || !browser)
return RV_CONTINUE;
CefRefPtr<CefFrame> framePtr;
if(frame)
framePtr = CefFrameCToCpp::Wrap(frame);
return CefHandlerCppToC::Get(self)->HandleLoadStart(
CefBrowserCToCpp::Wrap(browser), framePtr, isMainContent?true:false);
} <----------------- Error happens here