Fixed a reentrance issue in DownloadManagerImpl::PostInitialization().
DownloadManagerImpl::PostInitialization() is called twice, one by history db, one by download db. If History db is initialized first, it will call OnHistoryQueryComplete() and set load_history_downloads_cb_. If download db is ready later, it calls PostInitialization() and executes load_history_downloads_cb_ immediately. Since load_history_downloads_cb_ calls PostInitialization() again, we got an reentrance issue. BUG=900417 Change-Id: Ie89146f9bd7d30ca955601c7288e0f33c2e9e11b Reviewed-on: https://chromium-review.googlesource.com/c/1309218Reviewed-by:Shakti Sahu <shaktisahu@chromium.org> Commit-Queue: Min Qin <qinmin@chromium.org> Cr-Commit-Position: refs/heads/master@{#604386}
Showing
Please register or sign in to comment