Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(98)

Unified Diff: media/mojo/services/mojo_audio_output_stream.cc

Issue 2809673002: Fix double close in MojoAudioOutputStream. (Closed)
Patch Set: Fix typo Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/sync_socket_win.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/mojo/services/mojo_audio_output_stream.cc
diff --git a/media/mojo/services/mojo_audio_output_stream.cc b/media/mojo/services/mojo_audio_output_stream.cc
index 1be3171295cd7ef8c92b82afaf84dbbd656be57d..69e696901b35368b625332cfd76d1ec418da5978 100644
--- a/media/mojo/services/mojo_audio_output_stream.cc
+++ b/media/mojo/services/mojo_audio_output_stream.cc
@@ -71,7 +71,7 @@ void MojoAudioOutputStream::OnStreamCreated(
mojo::ScopedSharedBufferHandle buffer_handle = mojo::WrapSharedMemoryHandle(
foreign_memory_handle, shared_memory->requested_size(), false);
mojo::ScopedHandle socket_handle =
- mojo::WrapPlatformFile(foreign_socket->handle());
+ mojo::WrapPlatformFile(foreign_socket->Release());
Nico 2017/04/10 15:29:35 Should WrapPltformFile take an rvalue of some kind
Max Morin 2017/04/10 15:44:20 It should probably take a ScopedPlatformHandle (an
Nico 2017/04/10 15:50:37 Maybe at least file a bug.
Max Morin 2017/04/11 09:11:11 I filed crbug.com/710376 and also added checks for
DCHECK(buffer_handle.is_valid());
DCHECK(socket_handle.is_valid());
« no previous file with comments | « base/sync_socket_win.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698