summaryrefslogtreecommitdiff
path: root/fs/fs.c
diff options
context:
space:
mode:
authorJoao Marcos Costa <joaomarcos.costa@bootlin.com>2020-07-30 15:33:51 +0200
committerTom Rini <trini@konsulko.com>2020-08-07 22:31:32 -0400
commit02c366b5d5f7022e573732fbe7b80c199e934d4f (patch)
treef636035a6a099447901fef96928cbc0f9322e569 /fs/fs.c
parent3634b35089df7e6edfe034c26e4243dc708b6382 (diff)
downloadu-boot-02c366b5d5f7022e573732fbe7b80c199e934d4f.tar.gz
u-boot-02c366b5d5f7022e573732fbe7b80c199e934d4f.tar.bz2
u-boot-02c366b5d5f7022e573732fbe7b80c199e934d4f.zip
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>
Diffstat (limited to 'fs/fs.c')
-rw-r--r--fs/fs.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/fs.c b/fs/fs.c
index 5b31a369f7..17e4bc33f7 100644
--- a/fs/fs.c
+++ b/fs/fs.c
@@ -59,6 +59,9 @@ static int fs_ls_generic(const char *dirname)
if (dent->type == FS_DT_DIR) {
printf(" %s/\n", dent->name);
ndirs++;
+ } else if (dent->type == FS_DT_LNK) {
+ printf(" <SYM> %s\n", dent->name);
+ nfiles++;
} else {
printf(" %8lld %s\n", dent->size, dent->name);
nfiles++;