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

Unified Diff: content/renderer/media/audio_input_message_filter.cc

Issue 525313002: SyncSocket Transit Descriptor - refactoring (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Nits done - Prelanding checks Created 6 years, 3 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 | « content/common/media/audio_messages.h ('k') | content/renderer/media/audio_message_filter.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/media/audio_input_message_filter.cc
diff --git a/content/renderer/media/audio_input_message_filter.cc b/content/renderer/media/audio_input_message_filter.cc
index 02b0b57ba8a606d0f737bf46d250d9d4e3722a4f..171ddf8e126d1ae1bbac2731227faa7875166edc 100644
--- a/content/renderer/media/audio_input_message_filter.cc
+++ b/content/renderer/media/audio_input_message_filter.cc
@@ -23,7 +23,7 @@ void LogMessage(int stream_id, const std::string& msg) {
DVLOG(1) << oss.str();
}
-}
+} // namespace
namespace content {
@@ -126,19 +126,14 @@ void AudioInputMessageFilter::OnChannelClosing() {
void AudioInputMessageFilter::OnStreamCreated(
int stream_id,
base::SharedMemoryHandle handle,
-#if defined(OS_WIN)
- base::SyncSocket::Handle socket_handle,
-#else
- base::FileDescriptor socket_descriptor,
-#endif
+ base::SyncSocket::TransitDescriptor socket_descriptor,
uint32 length,
uint32 total_segments) {
DCHECK(io_message_loop_->BelongsToCurrentThread());
LogMessage(stream_id, "OnStreamCreated");
-#if !defined(OS_WIN)
- base::SyncSocket::Handle socket_handle = socket_descriptor.fd;
-#endif
+ base::SyncSocket::Handle socket_handle =
+ base::SyncSocket::UnwrapHandle(socket_descriptor);
media::AudioInputIPCDelegate* delegate = delegates_.Lookup(stream_id);
if (!delegate) {
DLOG(WARNING) << "Got audio stream event for a non-existent or removed"
« no previous file with comments | « content/common/media/audio_messages.h ('k') | content/renderer/media/audio_message_filter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698