diff options
author | Bhasker Hariharan <bhaskerh@google.com> | 2021-06-18 20:30:09 -0700 |
---|---|---|
committer | gVisor bot <gvisor-bot@google.com> | 2021-06-18 20:32:18 -0700 |
commit | aa8a6fa2f3c9daccb834a7e5ba558a8badb4a729 (patch) | |
tree | 551a8ec05b36552c0b51f67ac7a070eb7748346b /runsc/cmd/kill.go | |
parent | 081c463ad865e741f461baad349bc72a15fa04f0 (diff) |
Add endpoints to map only if registerEndpoint succeeds.
epsByNIC.registerEndpoint can add a multiportEndpoint to its map of
nic->multiportEndpoint even if multiport.Endpoint.singleRegisterEndpoint
failed. Same for transportDemuxer.singleRegisterEndpoint which ends up adding an
entry to nic->epsByNIC even if epsByNIC.registerEndpoint fails.
These breaks an invariant which the code assumes that a
multiportEndpoint/endpointsByNIC always have at least one valid entry.
PiperOrigin-RevId: 380310115
Diffstat (limited to 'runsc/cmd/kill.go')
0 files changed, 0 insertions, 0 deletions