mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-02-22 15:53:56 -04:00
fixed DataFlash_File_sd.cpp in case of SD error
This commit is contained in:
parent
c8d1dad493
commit
ccd90e19a1
@ -151,7 +151,8 @@ void DataFlash_File::periodic_1Hz(const uint32_t now)
|
||||
// likely to cause a crash.
|
||||
// _write_fd.close();
|
||||
_write_fd.sync();
|
||||
printf("\nLoging stopped\n");
|
||||
printf("\nLoging aborted\n");
|
||||
_open_error = true;
|
||||
_initialised = false;
|
||||
}
|
||||
}
|
||||
@ -820,6 +821,7 @@ uint16_t DataFlash_File::start_new_log(void)
|
||||
log_num = 1;
|
||||
if(was_ovf) {
|
||||
_initialised = false; // no space
|
||||
_open_error = true; // don't try any more
|
||||
printf("\nLoging stopped\n");
|
||||
return 0xFFFF;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user