> compile NEMU

221220000 张三
Linux zzy 5.15.146.1-microsoft-standard-WSL2 #1 SMP Thu Jan 11 04:09:03 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
 11:17:17 up 7 days, 11:17,  1 user,  load average: 0.04, 0.15, 0.11
This commit is contained in:
tracer-ics2023
2024-09-25 11:17:17 +08:00
committed by zzy
parent 8519414057
commit 7e5db071c8

View File

@ -56,7 +56,7 @@ void NDL_OpenCanvas(int *w, int *h) {
const char* pos = buf;
fread(buf, 1, sizeof(buf), fp);
int life = 2;
while (sscanf(pos, "%s:%d\n", name, &num) == 2 && life--) {
while (sscanf(pos, "%s%*[ \t]:%d\n", name, &num) == 2 && life--) {
printf("log:%s,%d\n", name, num);
pos = strchr(pos, '\n');
pos ++;