<div dir="ltr"><div><div><div>I'm using stat to display filesize and allocated size in my Android app.<br><br></div>I calculate the allocated size by multiplying the block count (%b) with 512 Byte.<br><br></div><div>I found out in <a href="https://github.com/landley/toybox/issues/41">https://github.com/landley/toybox/issues/41</a> that the blocksize for the blockcount calculation is hardcoded to 512. So this should work well (and has so far).<br></div><div><br></div>Now a user of my app noticed that on their F2FS filesystem the allocated size is suspiciously small:<br><a href="https://github.com/d4rken/sdmaid-public/issues/830">https://github.com/d4rken/sdmaid-public/issues/830</a><br><br></div><div>Specifically too small by a factor of 8, as if the blocksize used for blockcount calculation is 4096 (4096/512). <br><br>Could stat have a problem with calculating the blockcount on F2FS filesystems or am I overlooking something else?<br><br></div><div>~Matthias<br></div></div>