mirror of
https://github.com/brain-hackers/brain-config.git
synced 2024-11-05 09:48:03 +09:00
avoid bug if user puts in negative gpu mem
This commit is contained in:
parent
59fd8e82d3
commit
9199bf25ea
@ -166,7 +166,7 @@ do_memory_split() {
|
||||
[ -z "$CUR_GPU_MEM" ] && CUR_GPU_MEM=64
|
||||
## ask users what gpu_mem they want
|
||||
NEW_GPU_MEM=$(whiptail --inputbox "How much memory should the GPU have? e.g. 16/32/64/128/256" \
|
||||
20 70 "$CUR_GPU_MEM" 3>&1 1>&2 2>&3)
|
||||
20 70 -- "$CUR_GPU_MEM" 3>&1 1>&2 2>&3)
|
||||
if [ $? -eq 0 ]; then
|
||||
set_config_var gpu_mem "$NEW_GPU_MEM" /boot/config.txt
|
||||
ASK_TO_REBOOT=1
|
||||
|
Loading…
Reference in New Issue
Block a user