tail input handling done