commit | 702a779edb5d71d9f1be82713482a51ff69a8a3d | [log] [tgz] |
---|---|---|
author | Ray Chin <raychin@google.com> | Tue May 23 17:43:50 2023 +0800 |
committer | Ray Chin <raychin@google.com> | Tue May 23 09:49:19 2023 +0000 |
tree | e168a71821122be35eb2218a77e302042e6196df | |
parent | 34de7475705880e693af6bc31ba8f4aeaf7a02fb [diff] |
Fix overflow issue when computing ideal size of scratch partition The type of f_frsize is `unsigned long` which is 32 bit for some system so it will overflow after multiplied by f_bfree. This solution adds one more type casting to ensure the type is 64 bit unsigned integer during the computing. Bug: 281599020 Test: adb root; adb shell disable-verity Change-Id: I377ed722d5e245c235c3ae12ff66ac7e91d1d6e8