Bugfix: prevent crash when ending a recording (barometer present).

Fixes #1766.
This commit is contained in:
Dennis Guse
2023-12-09 10:04:28 +01:00
parent f80aaf00ec
commit 24212a226e
@@ -120,6 +120,10 @@ public final class SensorDataSet {
return;
}
if (value instanceof AtmosphericPressure) {
if (this.barometer == null) {
//TODO Quick fix. This shouldn't happen, but it does. May be a race condition?
return;
}
this.barometer.add((Raw<AtmosphericPressure>) data);
return;
}