mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 09:08:10 +02:00
hud: fix values printing
Oops...
Fixes: 595079c37c ("hud: extract float printf modifer selection logic to helper")
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20643>
This commit is contained in:
parent
63203f94e8
commit
ab9a9f702a
1 changed files with 3 additions and 3 deletions
|
|
@ -313,9 +313,9 @@ number_to_human_readable(double num, enum pipe_driver_query_type type,
|
|||
d /= divisor;
|
||||
unit++;
|
||||
}
|
||||
|
||||
sprintf(out, get_float_modifier(d), d);
|
||||
sprintf(out, "%s", units[unit]);
|
||||
int n = sprintf(out, get_float_modifier(d), d);
|
||||
if (n > 0)
|
||||
sprintf(&out[n], "%s", units[unit]);
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue