I am using different methods for different programs to control their resource management. When I used systemd-run for gimp(GNU image manipulation program), when picture's memory requirement is higher than limit(i.e. 300MB which I set), program crashed and closed. Is there any systemd-run method which provides both using it safely without crashing and limiting its memory to a limit?
I used below command to start it with systemd-run in its shortcut (i.e. its desktop file ) :
systemd-run --scope -p MemoryLimit=300M gimp-2.8 %U