• Jun Choi's avatar
    Remove callbacks bound to base::Unretained(this) in FidoBleDevice · 5e0a0c6a
    Jun Choi authored
    Replace callbacks in FidoBleDevice bound to base::Unretained(this) to
    callbacks bound to weak pointers. When user navigates away from the site
    calling the WebAuthN API while request is being dispatched, callbacks in
    FidoBleDevice may be invoked after FidoBleDevice is destroyed. This is
    especially the case when the user navigates away during pairing process.
    In this case, FidoBleDevice::OnReadControlPointLength() will be called
    after FidoBleDevice is destroyed.
    
    Bug: 877344
    Change-Id: I14ad94cfc9624c50eeee88feb1a12a6f8488c696
    Reviewed-on: https://chromium-review.googlesource.com/c/1335727Reviewed-by: default avatarJan Wilken Dörrie <jdoerrie@chromium.org>
    Commit-Queue: Jun Choi <hongjunchoi@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#607999}
    5e0a0c6a
fido_ble_device.cc 8.54 KB