Skip to content

Commit

Permalink
SCTP: fix wrong debug counting of bind_bucket
Browse files Browse the repository at this point in the history
Should not count it if the allocation of the object
is failed.

Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Li Zefan authored and David S. Miller committed Apr 10, 2008
1 parent e8c3875 commit 935a7f6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/sctp/socket.c
Original file line number Diff line number Diff line change
Expand Up @@ -5761,8 +5761,8 @@ static struct sctp_bind_bucket *sctp_bucket_create(
struct sctp_bind_bucket *pp;

pp = kmem_cache_alloc(sctp_bucket_cachep, GFP_ATOMIC);
SCTP_DBG_OBJCNT_INC(bind_bucket);
if (pp) {
SCTP_DBG_OBJCNT_INC(bind_bucket);
pp->port = snum;
pp->fastreuse = 0;
INIT_HLIST_HEAD(&pp->owner);
Expand Down

0 comments on commit 935a7f6

Please sign in to comment.