Commit 5a11ecd
authored
Fix integer overflow in disk size calculation for S3 storage (hestiacp#4488)
Resolved an issue with calculating available disk space when mounting a backup filesystem on S3 storage, which caused integer overflow due to values exceeding the 32-bit integer limit.
This change addresses the problem of receiving a negative value (-16MB) due to integer overflow when handling large available space values from S3 storage. The use of bc ensures accurate calculations for large numbers, preventing overflow issues.1 parent dd8f9fc commit 5a11ecd
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
178 | 178 | | |
179 | 179 | | |
180 | 180 | | |
181 | | - | |
| 181 | + | |
182 | 182 | | |
183 | 183 | | |
184 | 184 | | |
| |||
0 commit comments