diff options
author | Joerg Bornemann <joerg.bornemann@theqtcompany.com> | 2016-01-26 17:35:06 +0100 |
---|---|---|
committer | Joerg Bornemann <joerg.bornemann@theqtcompany.com> | 2016-01-26 17:54:48 +0000 |
commit | eeb18149fa6d796dd5202f080b828099a9187046 (patch) | |
tree | 49b32875d223c9efa3ce487989a9dc7cecba25cd /src/core/url_request_custom_job.h | |
parent | 9490ae8570c950e8120e498fbdc459f5754df0bf (diff) |
Fix occasional "WeakPtrs must be checked on the same sequenced thread."
Revert 7c7ee9a9, and fix the issue by passing a raw this pointer to
startAsync. Bind will take care of calling AddRef/Release for us.
Otherwise the WeakPtr would get assigned to the UI thread and must be
invalidated in the same.
Change-Id: Iee741dde521cf085a086e397a8154fa1384d58d1
Task-number: QTBUG-49670
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
Diffstat (limited to 'src/core/url_request_custom_job.h')
-rw-r--r-- | src/core/url_request_custom_job.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/core/url_request_custom_job.h b/src/core/url_request_custom_job.h index be5cae43c..a994c467a 100644 --- a/src/core/url_request_custom_job.h +++ b/src/core/url_request_custom_job.h @@ -87,8 +87,7 @@ private: int m_error; GURL m_redirect; bool m_started; - base::WeakPtrFactory<URLRequestCustomJob> m_weakFactoryIO; - base::WeakPtrFactory<URLRequestCustomJob> m_weakFactoryUI; + base::WeakPtrFactory<URLRequestCustomJob> m_weakFactory; friend class URLRequestCustomJobDelegate; |