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

Unified Diff: Source/modules/webgl/WebGLObject.cpp

Issue 1234883002: [Oilpan] Migrate classes under module/webgl onto oilpan heap (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 5 years, 4 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 | « Source/modules/webgl/WebGLObject.h ('k') | Source/modules/webgl/WebGLProgram.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/webgl/WebGLObject.cpp
diff --git a/Source/modules/webgl/WebGLObject.cpp b/Source/modules/webgl/WebGLObject.cpp
index e84eb24742224fd9c3c4e1434a74ccee96547c03..772b7238502c64ce25b9e0a0594b72472472e924 100644
--- a/Source/modules/webgl/WebGLObject.cpp
+++ b/Source/modules/webgl/WebGLObject.cpp
@@ -69,18 +69,11 @@ void WebGLObject::detach()
void WebGLObject::detachAndDeleteObject()
{
- // Helper method that pairs detachment with platform object
- // deletion.
+ // To ensure that all platform objects are deleted after being detached,
+ // this method does them together.
//
- // With Oilpan enabled, objects may end up being finalized without
- // having been detached first. Consequently, the objects force
- // detachment first before deleting the platform object. Without
- // Oilpan, the objects will have been detached from the 'parent'
- // objects first and do not separately require it when finalizing.
- //
- // However, as detach() is trivial, the individual WebGL
- // destructors will always call detachAndDeleteObject() rather
- // than do it based on Oilpan being enabled.
+ // The individual WebGL destructors need to call detachAndDeleteObject()
+ // rather than do it based on Oilpan GC.
detach();
deleteObject(nullptr);
}
« no previous file with comments | « Source/modules/webgl/WebGLObject.h ('k') | Source/modules/webgl/WebGLProgram.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698