diff options
author | Michael Pratt <mpratt@google.com> | 2020-01-06 09:27:35 -0800 |
---|---|---|
committer | gVisor bot <gvisor-bot@google.com> | 2020-01-06 09:29:19 -0800 |
commit | 6410387ff9b4f0dbe88325ea0e30776f5f3efd5d (patch) | |
tree | 782d236bce945ae1981c3a361a8d9be687d0e16e /test/util/rlimit_util.cc | |
parent | 83ab47e87badd8b46f784739903361d9f824fa2c (diff) |
Cleanup Shm reference handling
Currently, shm.Registry.FindByID will return Shm instances without taking an
additional reference on them, making it possible for them to disappear.
More explicitly handle references. All callers hold a reference for the
duration that they hold the instance. Registry.shms may transitively hold Shms
with no references, so it must TryIncRef to determine if they are still valid.
PiperOrigin-RevId: 288314529
Diffstat (limited to 'test/util/rlimit_util.cc')
0 files changed, 0 insertions, 0 deletions