diff options
Diffstat (limited to 'mojo/edk/system/channel_win.cc')
-rw-r--r-- | mojo/edk/system/channel_win.cc | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/mojo/edk/system/channel_win.cc b/mojo/edk/system/channel_win.cc index 3678835..1eeb2f6 100644 --- a/mojo/edk/system/channel_win.cc +++ b/mojo/edk/system/channel_win.cc @@ -121,17 +121,15 @@ class ChannelWin : public Channel, ScopedPlatformHandleVectorPtr GetReadPlatformHandles( size_t num_handles, - void** payload, - size_t* payload_size) override { + const void* extra_header, + size_t extra_header_size) override { size_t handles_size = sizeof(PlatformHandle) * num_handles; - if (handles_size > *payload_size) + if (handles_size > extra_header_size) return nullptr; - *payload_size -= handles_size; ScopedPlatformHandleVectorPtr handles( new PlatformHandleVector(num_handles)); - memcpy(handles->data(), - static_cast<const char*>(*payload) + *payload_size, handles_size); + memcpy(handles->data(), extra_header, handles_size); return handles; } |