mirror of
https://github.com/topjohnwu/Magisk
synced 2024-11-13 20:54:12 +01:00
Round sizes to nearest integer
This commit is contained in:
parent
754fafcfe9
commit
7da205f4c8
@ -86,8 +86,8 @@ int get_img_size(const char *img, int *used, int *total) {
|
||||
}
|
||||
if (status) continue;
|
||||
sscanf(tok, "%d/%d", used, total);
|
||||
*used = *used / 256 + 1;
|
||||
*total /= 256;
|
||||
*used = (*used + 255) / 256;
|
||||
*total = (*total + 128) / 256;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user