From: Philippe Teuwen Date: Tue, 24 Oct 2017 12:10:52 +0000 (+0200) Subject: Flush stdout when waiting for /dev/ttyACM0 X-Git-Tag: v3.1.0~147^2 X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/commitdiff_plain/8a50d606171df609f7a201f29b0a88e092fa6f40?ds=sidebyside;hp=-c Flush stdout when waiting for /dev/ttyACM0 --- 8a50d606171df609f7a201f29b0a88e092fa6f40 diff --git a/client/proxmark3.c b/client/proxmark3.c index f7a87f6d..99ba9fba 100644 --- a/client/proxmark3.c +++ b/client/proxmark3.c @@ -355,11 +355,13 @@ int main(int argc, char* argv[]) { sp = uart_open(argv[1]); } else { printf("Waiting for Proxmark to appear on %s ", argv[1]); + fflush(stdout); int openCount = 0; do { sp = uart_open(argv[1]); msleep(1000); printf("."); + fflush(stdout); } while(++openCount < 20 && (sp == INVALID_SERIAL_PORT || sp == CLAIMED_SERIAL_PORT)); printf("\n"); }