[PATCH] rtnetlink.3: tfix

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



It seems that the structure in this example doesn't
have a field named n.

Signed-off-by: Hu Keping <hukeping@xxxxxxxxxx>
---
 man3/rtnetlink.3 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/man3/rtnetlink.3 b/man3/rtnetlink.3
index 143be57..430206d 100644
--- a/man3/rtnetlink.3
+++ b/man3/rtnetlink.3
@@ -113,7 +113,7 @@ Creating a rtnetlink message to set the MTU of a device:
                              NLMSG_ALIGN(req.nh.nlmsg_len));
     rta\->rta_type = IFLA_MTU;
     rta\->rta_len = RTA_LENGTH(sizeof(unsigned int));
-    req.n.nlmsg_len = NLMSG_ALIGN(req.nh.nlmsg_len) +
+    req.nh.nlmsg_len = NLMSG_ALIGN(req.nh.nlmsg_len) +
                                   RTA_LENGTH(sizeof(mtu));
     memcpy(RTA_DATA(rta), &mtu, sizeof(mtu));
     send(rtnetlink_sk, &req, req.nh.nlmsg_len, 0);
-- 
2.8.0.GIT

--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Kernel Documentation]     [Netdev]     [Linux Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux