mirror of
https://github.com/adulau/aha.git
synced 2024-12-28 11:46:19 +00:00
SCTP: fix wrong debug counting of datamsg
Should not count it if the allocation of this object failed. Signed-off-by: Li Zefan <lizf@cn.fujitsu.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
2fa7527ba1
commit
e8c38751be
1 changed files with 3 additions and 2 deletions
|
@ -66,9 +66,10 @@ SCTP_STATIC struct sctp_datamsg *sctp_datamsg_new(gfp_t gfp)
|
|||
{
|
||||
struct sctp_datamsg *msg;
|
||||
msg = kmalloc(sizeof(struct sctp_datamsg), gfp);
|
||||
if (msg)
|
||||
if (msg) {
|
||||
sctp_datamsg_init(msg);
|
||||
SCTP_DBG_OBJCNT_INC(datamsg);
|
||||
SCTP_DBG_OBJCNT_INC(datamsg);
|
||||
}
|
||||
return msg;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue