components: Replace uses of ComPtr::GetAddressOf() with ComPtr::operator&
Microsoft::WRL::ComPtr<T>::GetAddressOf() is banned due to the ease of causing memory leaks. Also replace CopyTo(foo.GetAddressOf()) with As(&foo) since CopyTo(&foo) does not work if we are copying to different interfaces. Also replace QueryInterface(foo.GetAddressOf()) with QueryInterface(IID_PPV_ARGS(&foo)). Bug: 914910 Change-Id: I9bec0dbdc7e22519e7e5a31d93ef31ca9a654265 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2271522Reviewed-by:Daniel Cheng <dcheng@chromium.org> Reviewed-by:
Nico Weber <thakis@chromium.org> Commit-Queue: Xiaohan Wang <xhwang@chromium.org> Cr-Commit-Position: refs/heads/master@{#784491}
Showing
Please register or sign in to comment