1
0
mirror of https://github.com/mpv-player/mpv synced 2025-02-21 07:16:56 +00:00

player: show larger cache sizes in MB on status line

This commit is contained in:
wm4 2015-07-14 23:23:23 +02:00
parent 739d345d6c
commit 27708eee81

View File

@ -248,7 +248,11 @@ static void print_status(struct MPContext *mpctx)
} else {
saddf(&line, "%2ds", (int)s.ts_duration);
}
saddf(&line, "+%lldKB", (long long)(fill / 1024));
if (fill >= 1024 * 1024) {
saddf(&line, "+%lldMB", (long long)(fill / 1024 / 1024));
} else {
saddf(&line, "+%lldKB", (long long)(fill / 1024));
}
}
}