Make ConsoleReaderOutputStream deal correctly with synchronous tasks

The prompt-shuffling behavior requires that the last line on the console
be the command prompt.  This is only true while the console is waiting
on user input (during which time only asynchronously-running tasks will
print to the console).  After the user hits Enter, the prompt will no
longer be the last thing on the console until we again wait for user
input.

This change codifies these assumptions, and enables/forces CROS to behave
appropriately in both situations.

Bug: 6318905
Change-Id: Ia341142bb0a07050f86c9b4f3d68237cbc258310
2 files changed