succd: remove redundant if
This commit is contained in:
parent
fbf41203de
commit
f5d80a335f
|
@ -104,11 +104,9 @@ func (d *daemon) processOnce(_ context.Context) error {
|
|||
mbar := d.piraniMbar3.mbar
|
||||
if !d.safety.failsafe && mbar < 4e-6 {
|
||||
// Unrealistic result, Pirani probe probably disconnected. Failsafe mode.
|
||||
if !d.safety.failsafe {
|
||||
d.safety.failsafe = true
|
||||
klog.Errorf("SAFETY: Pirani probe seems disconnected; enabling failsafe mode")
|
||||
}
|
||||
}
|
||||
if d.safety.failsafe && mbar > 1e2 {
|
||||
d.safety.failsafe = false
|
||||
klog.Infof("SAFETY: Pirani probe value (%s) is plausible again; quitting failsafe mode", formatMbar(mbar))
|
||||
|
|
Loading…
Reference in a new issue