From cd91e7c7c21d1416e02c2936e9760bd6c20b6d81 Mon Sep 17 00:00:00 2001 From: ajacoutot Date: Tue, 22 Jul 2014 06:45:31 +0000 Subject: [PATCH] Drop the "... during install" comments; they were missing in several places and it makes things simpler: no need to check for file existence. discussed with and ok deraadt@ rpe@ --- distrib/miniroot/install.sh | 6 ++---- distrib/miniroot/install.sub | 18 +++++------------- 2 files changed, 7 insertions(+), 17 deletions(-) diff --git a/distrib/miniroot/install.sh b/distrib/miniroot/install.sh index 0366e4c2ee3..cf3d47ee947 100644 --- a/distrib/miniroot/install.sh +++ b/distrib/miniroot/install.sh @@ -1,5 +1,5 @@ #!/bin/ksh -# $OpenBSD: install.sh,v 1.251 2014/07/21 20:43:00 naddy Exp $ +# $OpenBSD: install.sh,v 1.252 2014/07/22 06:45:31 ajacoutot Exp $ # $NetBSD: install.sh,v 1.5.2.8 1996/08/27 18:15:05 gwr Exp $ # # Copyright (c) 1997-2009 Todd Miller, Theo de Raadt, Ken Westerback @@ -310,9 +310,7 @@ fi ) if grep -qs '^rtsol' /mnt/etc/hostname.*; then - [[ ! -f /mnt/etc/sysctl.conf ]] && \ - echo "# created during install" >/mnt/etc/sysctl.conf - echo 'net.inet6.icmp6.rediraccept=1 # 1=Accept IPv6 ICMP redirects (for hosts)' >>/mnt/etc/sysctl.conf + echo 'net.inet6.icmp6.rediraccept=1 # 1=Accept IPv6 ICMP redirects (for hosts)' >>/mnt/etc/sysctl.conf fi # Perform final steps common to both an install and an upgrade. diff --git a/distrib/miniroot/install.sub b/distrib/miniroot/install.sub index ac1a98fbb6a..7c44e56a1ba 100644 --- a/distrib/miniroot/install.sub +++ b/distrib/miniroot/install.sub @@ -1,4 +1,4 @@ -# $OpenBSD: install.sub,v 1.784 2014/07/20 20:08:44 deraadt Exp $ +# $OpenBSD: install.sub,v 1.785 2014/07/22 06:45:31 ajacoutot Exp $ # # Copyright (c) 1997-2009 Todd Miller, Theo de Raadt, Ken Westerback # All rights reserved. @@ -1798,8 +1798,7 @@ donetconfig() { apply() { if [[ $sshd == n ]]; then - echo "sshd_flags=NO # disabled during install" \ - >>/mnt/etc/rc.conf.local + echo "sshd_flags=NO" >>/mnt/etc/rc.conf.local fi if [[ $sshd_disableroot == y ]]; then sed "/^#\(PermitRootLogin\) yes/s//\1 no/" \ @@ -1807,30 +1806,23 @@ apply() cp /tmp/sshd_config /mnt/etc/ssh/sshd_config fi if [[ $ntpd == y ]]; then - echo "ntpd_flags= # enabled during install" \ - >>/mnt/etc/rc.conf.local + echo "ntpd_flags=" >>/mnt/etc/rc.conf.local [[ $ntpd_server == default ]] && ntpd_server=pool.ntp.org - echo "# created during install\nservers ${ntpd_server%% *}" \ - >/mnt/etc/ntpd.conf + echo "servers ${ntpd_server%% *}" >>/mnt/etc/ntpd.conf fi if [[ -n $aperture ]]; then - [[ ! -f /mnt/etc/sysctl.conf ]] && \ - echo "# created during install" >/mnt/etc/sysctl.conf echo "machdep.allowaperture=$aperture # See xf86(4)" \ >>/mnt/etc/sysctl.conf fi if [[ -n $lidsuspend ]]; then - [[ ! -f /mnt/etc/sysctl.conf ]] && \ - echo "# created during install" >/mnt/etc/sysctl.conf echo "machdep.lidsuspend=1 # Try to suspend on lid close" \ >>/mnt/etc/sysctl.conf fi if [[ $xdm == y && -x /mnt/usr/X11R6/bin/xdm ]]; then - echo "xdm_flags= # enabled during install" \ - >>/mnt/etc/rc.conf.local + echo "xdm_flags=" >>/mnt/etc/rc.conf.local fi if [[ $defcons == y ]]; then -- 2.20.1