Calling READ-CHAR-NO-HANG like that you won't know if the function returns NIL because no characters are available or eof.Eg. (read-char-no-hang) in an interactive session will always return NIL since your keyboard isn't fast enough and the buffer is empty and it return NIL when no char is ready. If you use (read-char-no-hang *STANDARD-INPUT* NIL 'eof) you'll se the symbol eof for end of stream and NIL when there are not char (yet) to read. Making a loop of this will make READ-CHAR so you might as well use (read-char) like this (read-char *STANDARD-INPUT* NIL 'eof), which will return the symbol eof when end of file (stream)