Ensure stdout/stderr are flushed when asking questions
commitd8d89d8d27794d493ed2aa9eba4649e6e3ff4a9d
authorDan McGee <dan@archlinux.org>
Fri, 1 Apr 2011 20:16:26 +0000 (1 15:16 -0500)
committerDan McGee <dan@archlinux.org>
Fri, 1 Apr 2011 20:18:52 +0000 (1 15:18 -0500)
tree07b32f59cc65835ae6b9045226683c4f3a201f19
parent7f6d986ac93e3465db6a4ed5c3ac77b72d890e68
Ensure stdout/stderr are flushed when asking questions

Addresses FS#23492, where the question was shown without knowing what
one was answering to. Ensure we flush our output streams before printing
the question, and flush the stream on which we ask the question before
waiting for an answer.

Signed-off-by: Dan McGee <dan@archlinux.org>
src/pacman/util.c