Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2395)

Unified Diff: chrome_frame/vtable_patch_manager.cc

Issue 244002: This fixes a crash in IE8 with ChromeFrame when a new tab was created. ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome_frame/protocol_sink_wrap.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome_frame/vtable_patch_manager.cc
===================================================================
--- chrome_frame/vtable_patch_manager.cc (revision 27143)
+++ chrome_frame/vtable_patch_manager.cc (working copy)
@@ -30,6 +30,15 @@
DCHECK(vtable);
for (MethodPatchInfo* it = patches; it->index_ != -1; ++it) {
+ if (it->stub_ != NULL) {
+ // If this DCHECK fires it means that we are using the same VTable
+ // information to patch two different interfaces.
+ DCHECK(false);
+ DLOG(ERROR) << "Attempting to patch two different VTables with the "
+ << "same VTable information";
+ continue;
+ }
+
PROC original_fn = vtable[it->index_];
FunctionStub* stub = FunctionStub::FromCode(original_fn);
if (stub != NULL) {
@@ -65,7 +74,7 @@
HRESULT UnpatchInterfaceMethods(MethodPatchInfo* patches) {
for (MethodPatchInfo* it = patches; it->index_ != -1; ++it) {
if (it->stub_) {
- DCHECK(it->stub_->absolute_target() ==
+ DCHECK(it->stub_->absolute_target() ==
reinterpret_cast<uintptr_t>(it->method_));
// Modify the stub to just jump directly to the original function.
it->stub_->BypassStub(reinterpret_cast<void*>(it->stub_->argument()));
Property changes on: chrome_frame\vtable_patch_manager.cc
___________________________________________________________________
Added: svn:eol-style
+ LF
« no previous file with comments | « chrome_frame/protocol_sink_wrap.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698