MCPcopy Create free account
hub / github.com/NetSys/bess / FindTuple

Method FindTuple

core/modules/wildcard_match.cc:278–288  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

276}
277
278int WildcardMatch::FindTuple(wm_hkey_t *mask) {
279 int i = 0;
280
281 for (const auto &tuple : tuples_) {
282 if (memcmp(&tuple.mask, mask, total_key_size_) == 0) {
283 return i;
284 }
285 i++;
286 }
287 return -ENOENT;
288}
289
290int WildcardMatch::AddTuple(wm_hkey_t *mask) {
291 if (tuples_.size() >= MAX_TUPLES) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected