added shared ptr in class TimeoutEventListener
raised issue with dynamic_pointer_cast (warning: broken build)