Fix #893: show symlink target in statusbar

This commit is contained in:
Arun Prakash Jana 2021-03-18 23:45:32 +05:30
parent 381b251fd0
commit c825a9e541
No known key found for this signature in database
GPG Key ID: A75979F35C080412
1 changed files with 6 additions and 0 deletions

View File

@ -5683,6 +5683,12 @@ static void statusbar(char *path)
addstr(coolsize(pent->size));
addch(' ');
addstr(ptr);
if (S_ISLNK(pent->mode) && (readlink(pent->name, g_buf, PATH_MAX) > 0))
{
addstr(" [-> ");
addstr(g_buf);
addch(']');
}
addch('\n');
}