From ad2b89c1f285d41bc32e52c7d49c82d70c47184e Mon Sep 17 00:00:00 2001 From: Rob Gill Date: Wed, 31 Oct 2018 10:12:03 +1000 Subject: [PATCH] Fix unset $l1d_mode Another instance of unset l1d_mode causing error "./spectre-meltdown-checker.sh: 3867: [: Illegal number:" --- spectre-meltdown-checker.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/spectre-meltdown-checker.sh b/spectre-meltdown-checker.sh index ae9ab91..595264a 100755 --- a/spectre-meltdown-checker.sh +++ b/spectre-meltdown-checker.sh @@ -3859,6 +3859,7 @@ check_CVE_2018_3646_linux() pstatus yellow UNKNOWN "can't find or read /sys/devices/system/cpu/vulnerabilities/l1tf" fi else + l1d_mode=-1 pstatus blue N/A "not testable in offline mode" fi @@ -3887,6 +3888,7 @@ check_CVE_2018_3646_linux() # we have no sysfs but were asked to use it only! msg="/sys vulnerability interface use forced, but it's not available!" status=UNK + l1d_mode=-1 fi if ! is_cpu_vulnerable "$cve"; then