net/procfs: handle opendir("/proc/net/") correctly

Change-Id: I092bade082ba673b30257add4f869ac5bfa55ca6
Signed-off-by: chao.an <anchao@xiaomi.com>
This commit is contained in:
chao.an 2020-12-01 14:57:38 +08:00 committed by Xiang Xiao
parent ad66ea51e5
commit dbd6e9be16

View File

@ -431,7 +431,7 @@ static int netprocfs_opendir(FAR const char *relpath,
level1->base.level = 1;
if (strcmp(relpath, "net") == 0)
if (strcmp(relpath, "net") == 0 || strcmp(relpath, "net/") == 0)
{
/* Count the number of network devices */