-
Kuo-Hsin Yang authored
When the ram_vs_swap_weight file is not available, the ram_swap_weight varialbe is zero. CalculateAvailableMemoryUserSpaceKB uses the ram_swap_weight variable as denominator and crashes. Always set ram_swap_weight to non-zero value to avoid the dividing by zero issue. Bug: b/171033232 Change-Id: I82e2cfd28ea21e57f3e6dd40f8cd68ee9f265c4d Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2503914 Commit-Queue: Brian Geffon <bgeffon@chromium.org> Reviewed-by:
Brian Geffon <bgeffon@chromium.org> Cr-Commit-Position: refs/heads/master@{#821714}
2aa57793