Add parens around *free in *free++ in mbp_count() so that mbp_count()
actually works. mbp_count() turns out only to be used in debugging code in if_patm_intr.c, so this bug did not affect much in practice. Found with: Coverity Prevent(tm) CID: 1943
This commit is contained in:
parent
097e1ea87f
commit
1c293049d9
@ -338,7 +338,7 @@ mbp_count(struct mbpool *p, u_int *used, u_int *card, u_int *free)
|
||||
}
|
||||
mtx_lock(&p->free_lock);
|
||||
SLIST_FOREACH(cf, &p->free_list, link)
|
||||
*free++;
|
||||
(*free)++;
|
||||
mtx_unlock(&p->free_lock);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user