summaryrefslogtreecommitdiffstats
path: root/ipc/test_util_mac.h
Commit message (Collapse)AuthorAgeFilesLines
* Switch to standard integer types in ipc/.avi2015-12-221-0/+1
| | | | | | | | | BUG=138542 TBR=tsepez@chromium.org Review URL: https://codereview.chromium.org/1546533002 Cr-Commit-Position: refs/heads/master@{#366527}
* Reland 1: "mac: Add auto-close and share-read-only functionality to ↵erikchen2015-10-241-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | SharedMemory." The original CL had a bug in the unit tests where an incorrect parameter was passed to mach_vm_region. > base::FileDescriptor has a property |auto_close| that is used to indicate that > when the object is passed to an IPC message, the message takes ownership of the > underlying OS handle. Since SharedMemoryHandle needs to be interchangeable with > base::FileDescriptor, I added a property with similar functionality named > |ownership_passes_to_ipc_|. > > The method ShareToProcess() is used to lower the current and maximum protection > of the underlying OS handle before it is transferred to a different process. I > implemented this functionality for Mach memory objects. > > BUG=535711 > Committed: https://crrev.com/033bbbcb63cab781552dfb435c035131c423de30 > Cr-Commit-Position: refs/heads/master@{#355880} BUG=535711 TBR=tsepez@chromium.org, mark@chromium.org Review URL: https://codereview.chromium.org/1422873002 Cr-Commit-Position: refs/heads/master@{#355941}
* Revert of mac: Add auto-close and share-read-only functionality to ↵erikchen2015-10-231-5/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SharedMemory. (patchset #5 id:80001 of https://codereview.chromium.org/1418113003/ ) Reason for revert: New unit-tests failing on 10.8 http://build.chromium.org/p/chromium.mac/builders/Mac10.8%20Tests/builds/10139/steps/base_unittests/logs/SharedMemoryMacMultiProcessTest.MachShareToProcessReadonly Original issue's description: > mac: Add auto-close and share-read-only functionality to Mach based SharedMemory. > > base::FileDescriptor has a property |auto_close| that is used to indicate that > when the object is passed to an IPC message, the message takes ownership of the > underlying OS handle. Since SharedMemoryHandle needs to be interchangeable with > base::FileDescriptor, I added a property with similar functionality named > |ownership_passes_to_ipc_|. > > The method ShareToProcess() is used to lower the current and maximum protection > of the underlying OS handle before it is transferred to a different process. I > implemented this functionality for Mach memory objects. > > BUG=535711 > > Committed: https://crrev.com/033bbbcb63cab781552dfb435c035131c423de30 > Cr-Commit-Position: refs/heads/master@{#355880} TBR=mark@chromium.org,tsepez@chromium.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=535711 Review URL: https://codereview.chromium.org/1421933002 Cr-Commit-Position: refs/heads/master@{#355908}
* mac: Add auto-close and share-read-only functionality to Mach based ↵erikchen2015-10-231-0/+5
| | | | | | | | | | | | | | | | | | | | SharedMemory. base::FileDescriptor has a property |auto_close| that is used to indicate that when the object is passed to an IPC message, the message takes ownership of the underlying OS handle. Since SharedMemoryHandle needs to be interchangeable with base::FileDescriptor, I added a property with similar functionality named |ownership_passes_to_ipc_|. The method ShareToProcess() is used to lower the current and maximum protection of the underlying OS handle before it is transferred to a different process. I implemented this functionality for Mach memory objects. BUG=535711 Review URL: https://codereview.chromium.org/1418113003 Cr-Commit-Position: refs/heads/master@{#355880}
* ipc: Write end-to-end tests for SharedMemoryHandle brokering on Mac.erikchen2015-10-121-1/+6
| | | | | | | | BUG=535711 Review URL: https://codereview.chromium.org/1397023002 Cr-Commit-Position: refs/heads/master@{#353628}
* ipc: Move Mac test utilities into their own file.erikchen2015-10-121-0/+50
They are about to be used by a second test suite. This CL is intended as a refactor with no behavioral change. BUG=535711 Review URL: https://codereview.chromium.org/1393723003 Cr-Commit-Position: refs/heads/master@{#353560}