mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-10 18:08:30 -04:00
AP_Logger: process pending rotate on arming
If the user arms the vehicle during the logging-persist-timeout we should rotate the log immediately.
This commit is contained in:
parent
f6b121ad87
commit
115751833b
@ -767,6 +767,10 @@ void AP_Logger_File::stop_logging(void)
|
|||||||
|
|
||||||
void AP_Logger_File::PrepForArming()
|
void AP_Logger_File::PrepForArming()
|
||||||
{
|
{
|
||||||
|
if (_rotate_pending) {
|
||||||
|
_rotate_pending = false;
|
||||||
|
stop_logging();
|
||||||
|
}
|
||||||
if (logging_started()) {
|
if (logging_started()) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user