Skip to content

Commit

Permalink
fix podman machine start log level detection
Browse files Browse the repository at this point in the history
Use logrus.IsLevelEnabled because this will cover all levels below it as
well. Currently this condition would fail for the trace log level.

Signed-off-by: Paul Holzinger <[email protected]>
  • Loading branch information
Luap99 authored and mheon committed Mar 30, 2022
1 parent 07c5946 commit 1e8c8e9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/machine/qemu/machine.go
Original file line number Diff line number Diff line change
Expand Up @@ -428,7 +428,7 @@ func (v *MachineVM) Start(name string, _ machine.StartOptions) error {

// Disable graphic window when not in debug mode
// Done in start, so we're not suck with the debug level we used on init
if logrus.GetLevel() != logrus.DebugLevel {
if !logrus.IsLevelEnabled(logrus.DebugLevel) {
cmd = append(cmd, "-display", "none")
}

Expand Down

0 comments on commit 1e8c8e9

Please sign in to comment.