summaryrefslogtreecommitdiffstats
path: root/player
diff options
context:
space:
mode:
Diffstat (limited to 'player')
-rw-r--r--player/osd.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/player/osd.c b/player/osd.c
index c775197276..0bdb368f7e 100644
--- a/player/osd.c
+++ b/player/osd.c
@@ -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));
+ }
}
}