fixed a small bug in host side