swtpm_setup: Redirect error output of swtpm_bios to stdout

Redirect the stderr output of swtpm_bioc to stdout so we can
capture the message.

Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
This commit is contained in:
Stefan Berger 2019-07-02 19:33:06 -04:00 committed by Stefan Berger
parent e36d7915a5
commit caee678bc4

View File

@ -882,9 +882,9 @@ init_tpm()
fi
TCSD_TCP_DEVICE_PORT=$TPM_PORT
output="$(swtpm_bios -c)"
output="$(swtpm_bios -c 2>&1)"
if [ $? -ne 0 ]; then
logerr "swtpm_bios -c -o failed: $output"
logerr "swtpm_bios -c failed: $output"
return 1
fi
logit "Successfully enabled and activated the TPM"