浏览代码

[IPV6]: sin6_port is net-endian

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Al Viro 19 年之前
父节点
当前提交
e2e38e819b
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      include/linux/in6.h

+ 1 - 1
include/linux/in6.h

@@ -53,7 +53,7 @@ extern const struct in6_addr in6addr_loopback;
 
 
 struct sockaddr_in6 {
 struct sockaddr_in6 {
 	unsigned short int	sin6_family;    /* AF_INET6 */
 	unsigned short int	sin6_family;    /* AF_INET6 */
-	__u16			sin6_port;      /* Transport layer port # */
+	__be16			sin6_port;      /* Transport layer port # */
 	__u32			sin6_flowinfo;  /* IPv6 flow information */
 	__u32			sin6_flowinfo;  /* IPv6 flow information */
 	struct in6_addr		sin6_addr;      /* IPv6 address */
 	struct in6_addr		sin6_addr;      /* IPv6 address */
 	__u32			sin6_scope_id;  /* scope id (new in RFC2553) */
 	__u32			sin6_scope_id;  /* scope id (new in RFC2553) */