ctrl+D end input catch