fixed stack b bug