sink, source: Do not dereference freed memory when freeing the next events