small bug fixed, avoid stack overflow(> 50)