Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
kenlig committed Sep 27, 2024
1 parent 9f83b57 commit 205e625
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion runtime/src/bpf_map/userspace/var_hash_map.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ long var_size_hash_map_impl::elem_update(const void *key, const void *value,
}
key_vec.assign((uint8_t *)key, (uint8_t *)key + _key_size);
value_vec.assign((uint8_t *)value, (uint8_t *)value + _value_size);
bool element_exists = map_impl.contains(key_vec);
bool element_exists = map_impl.find(key_vec) != map_impl.end();
// Check if the element exists...
if (flags == BPF_NOEXIST && element_exists) {
errno = EEXIST;
Expand Down

0 comments on commit 205e625

Please sign in to comment.