mirror of
https://github.com/genodelabs/genode.git
synced 2025-02-11 21:45:37 +00:00
Fix getdirentries in libc_ffat
This commit is contained in:
parent
bf91ea8926
commit
b86f0c8b32
@ -322,9 +322,6 @@ class Plugin : public Libc::Plugin
|
|||||||
FILINFO ffat_file_info;
|
FILINFO ffat_file_info;
|
||||||
FRESULT res;
|
FRESULT res;
|
||||||
|
|
||||||
const unsigned int index = *basep / sizeof(struct dirent);
|
|
||||||
f_readdir(_get_ffat_dir(fd), 0);
|
|
||||||
for (unsigned int i = 0; i <= index; i++) {
|
|
||||||
res = f_readdir(_get_ffat_dir(fd), &ffat_file_info);
|
res = f_readdir(_get_ffat_dir(fd), &ffat_file_info);
|
||||||
switch(res) {
|
switch(res) {
|
||||||
case FR_OK:
|
case FR_OK:
|
||||||
@ -340,7 +337,6 @@ class Plugin : public Libc::Plugin
|
|||||||
PERR("f_readdir() returned an unexpected error code");
|
PERR("f_readdir() returned an unexpected error code");
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if (ffat_file_info.fname[0] == 0) { /* no (more) entries */
|
if (ffat_file_info.fname[0] == 0) { /* no (more) entries */
|
||||||
if (verbose)
|
if (verbose)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user