Foreign io_service destruction fix