mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-23 00:58:37 -04:00
DataFlash: remove NuttX/VRBrain hack for mixed-case filenames
This commit is contained in:
parent
21f2b74096
commit
6c14924de3
@ -98,20 +98,6 @@ void DataFlash_File::Init()
|
||||
int ret;
|
||||
struct stat st;
|
||||
|
||||
#if CONFIG_HAL_BOARD == HAL_BOARD_PX4 || CONFIG_HAL_BOARD == HAL_BOARD_VRBRAIN
|
||||
// try to cope with an existing lowercase log directory
|
||||
// name. NuttX does not handle case insensitive VFAT well
|
||||
DIR *d = opendir("/fs/microsd/APM");
|
||||
if (d != nullptr) {
|
||||
for (struct dirent *de=readdir(d); de; de=readdir(d)) {
|
||||
if (strcmp(de->d_name, "logs") == 0) {
|
||||
rename("/fs/microsd/APM/logs", "/fs/microsd/APM/OLDLOGS");
|
||||
break;
|
||||
}
|
||||
}
|
||||
closedir(d);
|
||||
}
|
||||
#endif
|
||||
const char* custom_dir = hal.util->get_custom_log_directory();
|
||||
if (custom_dir != nullptr){
|
||||
_log_directory = custom_dir;
|
||||
|
Loading…
Reference in New Issue
Block a user