mirror of
https://github.com/u-boot/u-boot.git
synced 2025-04-19 11:24:42 +00:00
fs/fs.c: add symbolic link case to fs_ls_generic()
Adds an 'else if' statement inside the loop to check for symbolic links. Signed-off-by: Joao Marcos Costa <joaomarcos.costa@bootlin.com>
This commit is contained in:
parent
3634b35089
commit
02c366b5d5
1 changed files with 3 additions and 0 deletions
3
fs/fs.c
3
fs/fs.c
|
@ -59,6 +59,9 @@ static int fs_ls_generic(const char *dirname)
|
||||||
if (dent->type == FS_DT_DIR) {
|
if (dent->type == FS_DT_DIR) {
|
||||||
printf(" %s/\n", dent->name);
|
printf(" %s/\n", dent->name);
|
||||||
ndirs++;
|
ndirs++;
|
||||||
|
} else if (dent->type == FS_DT_LNK) {
|
||||||
|
printf(" <SYM> %s\n", dent->name);
|
||||||
|
nfiles++;
|
||||||
} else {
|
} else {
|
||||||
printf(" %8lld %s\n", dent->size, dent->name);
|
printf(" %8lld %s\n", dent->size, dent->name);
|
||||||
nfiles++;
|
nfiles++;
|
||||||
|
|
Loading…
Add table
Reference in a new issue