mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-22 01:11:42 +00:00
[wpilib] DataLogManager: Use logs subdirectory on USB drives (#5975)
This commit is contained in:
@@ -214,7 +214,10 @@ public final class DataLogManager {
|
||||
// prefer a mounted USB drive if one is accessible
|
||||
Path usbDir = Paths.get("/u").toRealPath();
|
||||
if (Files.isWritable(usbDir)) {
|
||||
return usbDir.toString();
|
||||
if (!new File("/u/logs").mkdir()) {
|
||||
// ignored
|
||||
}
|
||||
return "/u/logs";
|
||||
}
|
||||
} catch (IOException ex) {
|
||||
// ignored
|
||||
|
||||
Reference in New Issue
Block a user