user/vmm: fflush stdout on every write
authorRonald G. Minnich <rminnich@gmail.com>
Tue, 22 Nov 2016 00:01:03 +0000 (16:01 -0800)
committerBarret Rhoden <brho@cs.berkeley.edu>
Tue, 29 Nov 2016 16:00:06 +0000 (11:00 -0500)
Things are not reliable enough yet to assume a final fflush
on stdout will happen. Just fflush on every character.

Change-Id: Ib24b6844205849b7d50882ff1724bd46a19ba4b3
Signed-off-by: Ronald G. Minnich <rminnich@gmail.com>
Signed-off-by: Barret Rhoden <brho@cs.berkeley.edu>
user/vmm/vmexit.c

index 4404ec9..52479cd 100644 (file)
@@ -130,6 +130,7 @@ static bool handle_vmcall(struct guest_thread *gth)
        printf("%c", byte);
        if (byte == '\n')
                printf("%c", '%');
+       fflush(stdout);
        vm_tf->tf_rip += 3;
        return TRUE;
 }