mirror of
https://github.com/storytold/photocraft.git
synced 2026-11-12 21:23:02 +00:00
With 1 GiB or less of free RAM, or 512 MiB or less of commit headroom, the hard limit was exactly 0, so even a small file was refused with a message that didn't say memory was low. The reserve now shrinks with the measurement: up to a quarter of free RAM opens automatically, the rest goes to approval, and an approved import always leaves at least 256 MiB free. Limits are unchanged for automatic opening above 4/3 GiB free and for approval from 4 GiB free. A refusal set by measured memory now gives the free amount and says to close other apps and try again, and the approval prompt warns when little memory would be left. An unreadable cgroup still measures Some(0) and stays refused.