Mojo: Fix wrapping of invalid SharedMemoryHandles.
When wrapping an invalid SharedMemoryHandle, we should always just return a null ScopedSharedBufferHandle. Currently we return a non-null ScopedSharedBufferHandle which wraps an invalid platform handle. This will always fail to serialize and is generally bad. Also fixes DiscardableSharedMemoryManager mojom to allow a null shared buffer handle in the response to AllocateLockedDiscardableSharedMemory. The existing client implementation already handles the null case, so no additional code changes are required BUG=674406 Review-Url: https://codereview.chromium.org/2583583002 Cr-Commit-Position: refs/heads/master@{#438955}
Showing
Please register or sign in to comment