Speculative fix for crash on MTP directory read.
Within MTPDeviceDelegateImplLinux::ReadDirectoryInternal, the call to PendingRequestDone at the end of the function allowed for another task to run and potentially delete the file_id from the cache prior to the directory listing being done. This would then cause a nullptr dereference in OnDidReadDirectory which expects the cache entry to exist. Since ReadDirectoryInternal is only run from a task, just continue the task instead of posting it to the request queue. BUG=817523 Change-Id: I9df651864ba1ef3c26365832b149871b027f99d5 Reviewed-on: https://chromium-review.googlesource.com/1195202Reviewed-by:Lei Zhang <thestig@chromium.org> Commit-Queue: Anand Mistry <amistry@chromium.org> Cr-Commit-Position: refs/heads/master@{#587857}
Showing
Please register or sign in to comment