提交 0e2bedaa 编写于 作者: S Steve French

[CIFS] ipv6_addr_equal for address comparison

Signed-off-by: NJeff Layton <jlayton@redhat.com>
Signed-off-by: NSteve French <sfrench@us.ibm.com>
上级 f2257b70
...@@ -23,7 +23,6 @@ ...@@ -23,7 +23,6 @@
#include <linux/string.h> #include <linux/string.h>
#include <linux/list.h> #include <linux/list.h>
#include <linux/wait.h> #include <linux/wait.h>
#include <linux/ipv6.h>
#include <linux/pagemap.h> #include <linux/pagemap.h>
#include <linux/ctype.h> #include <linux/ctype.h>
#include <linux/utsname.h> #include <linux/utsname.h>
...@@ -35,6 +34,7 @@ ...@@ -35,6 +34,7 @@
#include <linux/freezer.h> #include <linux/freezer.h>
#include <asm/uaccess.h> #include <asm/uaccess.h>
#include <asm/processor.h> #include <asm/processor.h>
#include <net/ipv6.h>
#include "cifspdu.h" #include "cifspdu.h"
#include "cifsglob.h" #include "cifsglob.h"
#include "cifsproto.h" #include "cifsproto.h"
...@@ -1379,8 +1379,8 @@ cifs_find_tcp_session(struct sockaddr_storage *addr) ...@@ -1379,8 +1379,8 @@ cifs_find_tcp_session(struct sockaddr_storage *addr)
server->addr.sockAddr.sin_addr.s_addr)) server->addr.sockAddr.sin_addr.s_addr))
continue; continue;
else if (addr->ss_family == AF_INET6 && else if (addr->ss_family == AF_INET6 &&
memcmp(&server->addr.sockAddr6.sin6_addr, !ipv6_addr_equal(&server->addr.sockAddr6.sin6_addr,
&addr6->sin6_addr, sizeof(addr6->sin6_addr))) &addr6->sin6_addr))
continue; continue;
++server->srv_count; ++server->srv_count;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册