random.4: Use modern command substitution syntax in shell session log

Reported-by: Walter Harms <wharms@bfs.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
Michael Kerrisk 2015-12-20 21:58:12 +01:00
parent 9f4d4bebe0
commit ff76b2999b
1 changed files with 2 additions and 2 deletions

View File

@ -186,7 +186,7 @@ which is run during the Linux system start-up sequence:
fi
chmod 600 $random_seed
poolfile=/proc/sys/kernel/random/poolsize
[ \-r $poolfile ] && bits=\`cat $poolfile\` || bits=4096
[ \-r $poolfile ] && bits=$(cat $poolfile) || bits=4096
bytes=$(expr $bits / 8)
dd if=/dev/urandom of=$random_seed count=1 bs=$bytes
.fi
@ -202,7 +202,7 @@ run during the Linux system shutdown:
touch $random_seed
chmod 600 $random_seed
poolfile=/proc/sys/kernel/random/poolsize
[ \-r $poolfile ] && bits=\`cat $poolfile\` || bits=4096
[ \-r $poolfile ] && bits=$(cat $poolfile) || bits=4096
bytes=$(expr $bits / 8)
dd if=/dev/urandom of=$random_seed count=1 bs=$bytes
.fi