Avoid burning 100% CPU

Adds hl_usleep() like in the other version of getmyline().
pull/1831/head
Daniele Forsi IU5HKX 2025-08-05 21:16:33 +02:00
rodzic d9532a9c62
commit 8064da8121
1 zmienionych plików z 5 dodań i 0 usunięć

Wyświetl plik

@ -131,5 +131,10 @@ getmyline5(int fd, unsigned char *buf)
printf("n=%d %02x %02x %02x %02x %02x\n", n, buf[0], buf[1], buf[2], buf[3],
buf[4]);
if (i == 0) {
hl_usleep(10 * 1000);
}
return n;
}