Przeglądaj źródła

Only disable ctrl-alt-del once

Bob Mottram 8 lat temu
rodzic
commit
7e24becb9c
1 zmienionych plików z 4 dodań i 1 usunięć
  1. 4
    1
      src/freedombone-utils-setup

+ 4
- 1
src/freedombone-utils-setup Wyświetl plik

500
 }
500
 }
501
 
501
 
502
 function disable_ctrl_alt_del {
502
 function disable_ctrl_alt_del {
503
-    ln -sf /dev/null /etc/systemd/system/ctrl-alt-del.target
503
+    ctrl_alt_del=$(ls -l /etc/systemd/system/ctrl-alt-del.target)
504
+    if [[ "$ctrl_alt_del" !=  *'/dev/null' ]]; then
505
+        ln -sf /dev/null /etc/systemd/system/ctrl-alt-del.target
506
+    fi
504
 }
507
 }
505
 
508
 
506
 function lockdown_permissions {
509
 function lockdown_permissions {