| Index: content/browser/file_descriptor_info_impl.cc
|
| diff --git a/content/browser/file_descriptor_info_impl.cc b/content/browser/file_descriptor_info_impl.cc
|
| index c6cf831e6258333c8a3a1ad148d1bca7a8440ef5..7a61402f9eb9813e7ff7410584f6336901b2d978 100644
|
| --- a/content/browser/file_descriptor_info_impl.cc
|
| +++ b/content/browser/file_descriptor_info_impl.cc
|
| @@ -25,7 +25,7 @@ void FileDescriptorInfoImpl::Share(int id, base::PlatformFile fd) {
|
|
|
| void FileDescriptorInfoImpl::Transfer(int id, base::ScopedFD fd) {
|
| AddToMapping(id, fd.get());
|
| - owned_descriptors_.push_back(new base::ScopedFD(std::move(fd)));
|
| + owned_descriptors_.push_back(std::move(fd));
|
| }
|
|
|
| base::PlatformFile FileDescriptorInfoImpl::GetFDAt(size_t i) const {
|
| @@ -53,7 +53,7 @@ bool FileDescriptorInfoImpl::OwnsFD(base::PlatformFile file) const {
|
| return owned_descriptors_.end() !=
|
| std::find_if(
|
| owned_descriptors_.begin(), owned_descriptors_.end(),
|
| - [file](const base::ScopedFD* fd) { return fd->get() == file; });
|
| + [file](const base::ScopedFD& fd) { return fd.get() == file; });
|
| }
|
|
|
| base::ScopedFD FileDescriptorInfoImpl::ReleaseFD(base::PlatformFile file) {
|
| @@ -62,9 +62,9 @@ base::ScopedFD FileDescriptorInfoImpl::ReleaseFD(base::PlatformFile file) {
|
| base::ScopedFD fd;
|
| auto found = std::find_if(
|
| owned_descriptors_.begin(), owned_descriptors_.end(),
|
| - [file](const base::ScopedFD* fd) { return fd->get() == file; });
|
| + [file](const base::ScopedFD& fd) { return fd.get() == file; });
|
|
|
| - (*found)->swap(fd);
|
| + found->swap(fd);
|
| owned_descriptors_.erase(found);
|
|
|
| return fd;
|
|
|