1. fix a bug. (change tail->next)