mirror of https://github.com/CISOfy/lynis.git
[KRNL-5830] Readability and style improvements
This commit is contained in:
parent
0993c0a13b
commit
ff38336e0b
|
@ -460,12 +460,12 @@
|
|||
LogText "Test: Checking presence ${FILE}"
|
||||
if [ -f ${FILE} ]; then
|
||||
LogText "Result: file ${FILE} exists"
|
||||
FIND=`cat ${FILE}`
|
||||
if [ "${FIND}" = "" ]; then
|
||||
FIND=$(wc -l < ${FILE})
|
||||
if [ "${FIND}" = "0" ]; then
|
||||
LogText "Result: No reboot needed (file empty)"
|
||||
REBOOT_NEEDED=0
|
||||
else
|
||||
PKGSCOUNT=`cat ${FILE} | wc -l`
|
||||
PKGSCOUNT=$(wc -l < {FILE})
|
||||
LogText "Result: reboot is needed, related to ${PKGSCOUNT} packages"
|
||||
for I in ${FIND}; do
|
||||
LogText "Package: ${I}"
|
||||
|
@ -478,7 +478,7 @@
|
|||
# Check if /boot exists
|
||||
if [ -d /boot ]; then
|
||||
LogText "Result: /boot exists, performing more tests from here"
|
||||
FIND=`ls /boot/* 2> /dev/null`
|
||||
FIND=$(ls /boot/* 2> /dev/null)
|
||||
if [ ! "${FIND}" = "" ]; then
|
||||
if [ -f /boot/vmlinuz -a ! -L /boot/vmlinuz ]; then
|
||||
LogText "Result: found /boot/vmlinuz (not symlinked)"
|
||||
|
|
Loading…
Reference in New Issue