This patch replaces std::vector with std::map for the oobs struct
when matching strings for callbacks. With std::vector it was
possible that we could continually add callbacks with the same prefix
and eventually run out of memory. By design it seems that the vrecv
only invokes the callback for the first prefix match, so duplicate
prefixes would never have their callbacks invoked.
This patch replaces std::vector with std::map for the oobs struct when matching strings for callbacks. With std::vector it was possible that we could continually add callbacks with the same prefix and eventually run out of memory. By design it seems that the vrecv only invokes the callback for the first prefix match, so duplicate prefixes would never have their callbacks invoked.
Signed-off-by: Ryan Sherlock ryan.m.sherlock@gmail.com