Skip to content

Commit 5cf53e6

Browse files
Fix empty constructor for Dir object in DOSFS
1 parent 72ababf commit 5cf53e6

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

cores/stm32l4/FS.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,11 @@ Dir::Dir(const char* path) {
140140
}
141141
}
142142

143+
Dir::Dir() {
144+
_path[0] = '\0';
145+
_find.find_clsno = 0x0fffffff;
146+
};
147+
143148
File Dir::openFile(const char* mode) {
144149
char filename[F_MAXPATH];
145150

cores/stm32l4/FS.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ class File : public Stream
6666
class Dir {
6767
public:
6868
Dir(const char *path);
69-
~Dir();
69+
Dir();
7070

7171
File openFile(const char* mode);
7272
String fileName();

0 commit comments

Comments
 (0)