[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <F8A1B797-89A2-4AAA-AFB1-9B187AC08456@sfc.wide.ad.jp>
Date: Fri, 10 Jun 2011 17:07:56 +0900
From: Michio Honda <micchie@....wide.ad.jp>
To: David Miller <davem@...emloft.net>
Cc: Wei Yongjun <yjwei@...fujitsu.com>, netdev@...r.kernel.org
Subject: [PATCH] sctp: kzalloc() error handling on deleting last address
>From 49a66ecad72af8c367b125c695a113d3f3870320 Mon Sep 17 00:00:00 2001
From: Michio Honda <micchie@....wide.ad.jp>
Date: Fri, 10 Jun 2011 16:42:14 +0900
Subject: [PATCH] sctp: kzalloc() error handling on deleting last address
Signed-off-by: Michio Honda <micchie@....wide.ad.jp>
---
net/sctp/socket.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/net/sctp/socket.c b/net/sctp/socket.c
index e7e1b14..a23d898 100644
--- a/net/sctp/socket.c
+++ b/net/sctp/socket.c
@@ -786,6 +786,8 @@ static int sctp_send_asconf_del_ip(struct sock *sk,
continue;
asoc->asconf_addr_del_pending =
kzalloc(sizeof(union sctp_addr), GFP_ATOMIC);
+ if (asoc->asconf_addr_del_pending == NULL)
+ continue;
asoc->asconf_addr_del_pending->sa.sa_family =
addrs->sa_family;
asoc->asconf_addr_del_pending->v4.sin_port =
--
1.7.3.2
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists