1
0
Fork 0

[PATCH] Array overrun in drivers/infiniband/core/cma.c

This was spotted by coverity #id 1300.  Since the array has only four
elements, we should just use those four.

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Acked-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
hifive-unleashed-5.1
Eric Sesterhenn 2006-06-21 20:56:26 +02:00 committed by Linus Torvalds
parent 09c0dc6862
commit 5fd571cbc1
1 changed files with 1 additions and 1 deletions

View File

@ -476,7 +476,7 @@ static inline int cma_zero_addr(struct sockaddr *addr)
else {
ip6 = &((struct sockaddr_in6 *) addr)->sin6_addr;
return (ip6->s6_addr32[0] | ip6->s6_addr32[1] |
ip6->s6_addr32[3] | ip6->s6_addr32[4]) == 0;
ip6->s6_addr32[2] | ip6->s6_addr32[3]) == 0;
}
}