mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 16:23:55 -06:00
cutils: Support 'P' and 'E' suffixes in strtosz()
Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
This commit is contained in:
parent
a23818f4ff
commit
5e00984aef
5 changed files with 20 additions and 12 deletions
|
@ -267,6 +267,10 @@ static int64_t suffix_mul(char suffix, int64_t unit)
|
|||
return unit * unit * unit;
|
||||
case STRTOSZ_DEFSUFFIX_TB:
|
||||
return unit * unit * unit * unit;
|
||||
case STRTOSZ_DEFSUFFIX_PB:
|
||||
return unit * unit * unit * unit * unit;
|
||||
case STRTOSZ_DEFSUFFIX_EB:
|
||||
return unit * unit * unit * unit * unit * unit;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue