Fix crash when responding to request that was previously cancelled by CEF (e.g. due to page reload)

This commit is contained in:
jankurianski
2014-07-31 18:43:28 +10:00
parent a29f56421c
commit 454d0dfbf5
+5 -1
View File
@@ -61,7 +61,11 @@ namespace CefSharp
_headers = ToHeaderMap(response->ResponseHeaders);
_callback->Continue();
// If CEF has cancelled the initial request, throw away a response that comes afterwards.
if (_callback != nullptr)
{
_callback->Continue();
}
// Must be done AFTER CEF has been allowed to consume the headers etc. After this call is made, the SchemeHandlerWrapper
// instance has likely been deallocated.