Fix off-screen browser leak in cefclient osrplugin example.

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@328 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt 2011-10-19 16:51:21 +00:00
parent 026dacda76
commit 7a07aaf5f1
1 changed files with 3 additions and 0 deletions

View File

@ -594,6 +594,9 @@ LRESULT CALLBACK PluginWndProc(HWND hWnd, UINT message, WPARAM wParam,
case WM_DESTROY:
// Stop the timer that's used for redrawing.
KillTimer(hWnd, 1);
// Explicitly close the offscreen browser and release the reference.
g_offscreenBrowser->CloseBrowser();
g_offscreenBrowser = NULL;
return 0;