Browse Source

Read amd_master using print -rn, fixes problems if the file has multiple

lines. Problem noticed by me, this solution from halex@.
ok halex aja
OPENBSD_5_1
nicm 13 years ago
parent
commit
629fd2b83a
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      src/etc/rc.d/amd

+ 2
- 2
src/etc/rc.d/amd View File

@ -1,6 +1,6 @@
#!/bin/sh
#
# $OpenBSD: amd,v 1.3 2011/07/16 09:33:29 sthen Exp $
# $OpenBSD: amd,v 1.4 2011/08/22 08:02:04 nicm Exp $
daemon="/usr/sbin/amd"
@ -12,7 +12,7 @@ rc_stop=NO
rc_pre() {
[ -e ${amd_master} ] || return 1
daemon_flags=$(cat ${amd_master})
daemon_flags=$(print -rn -- $(< ${amd_master}))
}
rc_start() {


Loading…
Cancel
Save