summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorKozlov Dmitry <xeb@mail.ru>2012-08-13 13:16:28 +0400
committerKozlov Dmitry <xeb@mail.ru>2012-08-13 13:16:28 +0400
commit1dee68d4f684d7bf155ad9271ab154f4b7418702 (patch)
tree5293b8d47866904318b97cddb177755f38973cce /drivers
parent892f7b726b5b7fadc9d565b2e3d22566be346d60 (diff)
downloadaccel-ppp-1dee68d4f684d7bf155ad9271ab154f4b7418702.tar.gz
accel-ppp-1dee68d4f684d7bf155ad9271ab154f4b7418702.zip
snapshot
Diffstat (limited to 'drivers')
-rw-r--r--drivers/ipoe/ipoe.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/ipoe/ipoe.c b/drivers/ipoe/ipoe.c
index b396866..97a37b2 100644
--- a/drivers/ipoe/ipoe.c
+++ b/drivers/ipoe/ipoe.c
@@ -1255,9 +1255,10 @@ static int fill_info(struct sk_buff *skb, struct ipoe_session *ses, u32 pid, u32
if (!hdr)
return -EMSGSIZE;
- NLA_PUT_U32(skb, IPOE_ATTR_IFINDEX, ses->dev->ifindex);
- NLA_PUT_U32(skb, IPOE_ATTR_PEER_ADDR, ses->peer_addr);
- NLA_PUT_U32(skb, IPOE_ATTR_ADDR, ses->addr);
+ if (nla_put_u32(skb, IPOE_ATTR_IFINDEX, ses->dev->ifindex) ||
+ nla_put_u32(skb, IPOE_ATTR_PEER_ADDR, ses->peer_addr) ||
+ nla_put_u32(skb, IPOE_ATTR_ADDR, ses->addr))
+ goto nla_put_failure;
return genlmsg_end(skb, hdr);