netif: fix stat() on "stats" and "ifstats" files in network interface
the kernel would go into endless loop when stating "stats" and "ifstats" files and the network interface having no connections, or otherwise return wrong stat info.
This commit is contained in:
parent
00ba1aac9e
commit
5bcc932168
1 changed files with 1 additions and 1 deletions
|
@ -67,7 +67,7 @@ netifgen(Chan *c, char*, Dirtab *vp, int, int i, Dir *dp)
|
|||
|
||||
/* second level contains clone plus all the conversations */
|
||||
t = NETTYPE(c->qid.path);
|
||||
if(t == N2ndqid || t == Ncloneqid || t == Naddrqid){
|
||||
if(t == N2ndqid || t == Ncloneqid || t == Naddrqid || t == Nstatqid || t == Nifstatqid){
|
||||
switch(i) {
|
||||
case DEVDOTDOT:
|
||||
q.type = QTDIR;
|
||||
|
|
Loading…
Reference in a new issue