C++ address change of a std::vector member after std::function call defined in mother class I have two classes that works like this: