Index: third_party/WebKit/Source/core/loader/ThreadableLoader.h |
diff --git a/third_party/WebKit/Source/core/loader/ThreadableLoader.h b/third_party/WebKit/Source/core/loader/ThreadableLoader.h |
index 3d2b2d20aff83707451037ea35d51a712d6890a3..1d77bee34bc34bb4ac09114cb7e1711b77c75d76 100644 |
--- a/third_party/WebKit/Source/core/loader/ThreadableLoader.h |
+++ b/third_party/WebKit/Source/core/loader/ThreadableLoader.h |
@@ -152,9 +152,9 @@ public: |
// After any of these methods is called, the loader won't call any of the |
// ThreadableLoaderClient methods. |
// |
- // When a ThreadableLoader is destructed, any of the |
- // ThreadableLoaderClient methods is NOT called in response to the |
- // destruction either synchronously or after destruction. |
+ // A user must guarantee that the loading complete before the attached |
+ // client gets invalid. Also, a user must guarantee that the loading |
hiroshige
2016/07/19 06:56:14
nits:
s/loading complete /loading completes /
s/th
yhirano
2016/07/19 08:05:03
Done.
|
+ // completes before the threadable loader is destructed. |
// |
// When ThreadableLoader::cancel() is called, |
// ThreadableLoaderClient::didFail() is called with a ResourceError |
@@ -167,6 +167,9 @@ public: |
// - may call cancel() |
// - can destroy the ThreadableLoader instance in them (by clearing |
// std::unique_ptr<ThreadableLoader>). |
+ // |
+ // A ThreadableLoader can be destructed only when the loading has already |
+ // completed. |
hiroshige
2016/07/19 06:56:14
Is this equivalent to the comment in Lines 156--15
yhirano
2016/07/19 08:05:04
Thanks, fixed.
|
static std::unique_ptr<ThreadableLoader> create(ExecutionContext&, ThreadableLoaderClient*, const ThreadableLoaderOptions&, const ResourceLoaderOptions&); |
// The methods on the ThreadableLoaderClient passed on create() call |