Skip to content
This repository has been archived by the owner on May 12, 2021. It is now read-only.

Commit

Permalink
qemu: fix error message miss
Browse files Browse the repository at this point in the history
strErr is qemu log message, should add err in error message, or if fail
before launch qemu, can not get corrent message.

Fixes: #1991

Signed-off-by: Ace-Tang <[email protected]>
  • Loading branch information
Ace-Tang committed Aug 21, 2019
1 parent 1935bf1 commit 50d4188
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion virtcontainers/qemu.go
Original file line number Diff line number Diff line change
Expand Up @@ -748,7 +748,7 @@ func (q *qemu) startSandbox(timeout int) error {
var strErr string
strErr, err = govmmQemu.LaunchQemu(q.qemuConfig, newQMPLogger())
if err != nil {
return fmt.Errorf("%s", strErr)
return fmt.Errorf("fail to launch qemu: %s, error messages from qemu log: %s", err, strErr)
}

err = q.waitSandbox(timeout) // the virtiofsd deferred checks err's value
Expand Down

0 comments on commit 50d4188

Please sign in to comment.