kopia lustrzana https://github.com/meshtastic/firmware
Avoid acquiring lock twice (#7555)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>pull/7502/head^2
rodzic
27c6b24e3a
commit
a23c58c10a
|
@ -112,9 +112,8 @@ bool NAU7802Sensor::saveCalibrationData()
|
|||
} else {
|
||||
okay = true;
|
||||
}
|
||||
spiLock->lock();
|
||||
// Note: SafeFile::close() already acquires the lock and releases it internally
|
||||
okay &= file.close();
|
||||
spiLock->unlock();
|
||||
|
||||
return okay;
|
||||
}
|
||||
|
|
Ładowanie…
Reference in New Issue