(src, dst uuid.UUID)
| 164 | } |
| 165 | |
| 166 | func (s *tunnelStore) add(src, dst uuid.UUID) { |
| 167 | srcM, ok := s.bySrc[src] |
| 168 | if !ok { |
| 169 | srcM = make(map[uuid.UUID]struct{}) |
| 170 | s.bySrc[src] = srcM |
| 171 | } |
| 172 | srcM[dst] = struct{}{} |
| 173 | dstM, ok := s.byDst[dst] |
| 174 | if !ok { |
| 175 | dstM = make(map[uuid.UUID]struct{}) |
| 176 | s.byDst[dst] = dstM |
| 177 | } |
| 178 | dstM[src] = struct{}{} |
| 179 | } |
| 180 | |
| 181 | func (s *tunnelStore) remove(src, dst uuid.UUID) { |
| 182 | delete(s.bySrc[src], dst) |
no outgoing calls