diff --git a/src/capwap/sock_cmpaddr.c b/src/capwap/sock_cmpaddr.c index 1613e752..f59941f9 100644 --- a/src/capwap/sock_cmpaddr.c +++ b/src/capwap/sock_cmpaddr.c @@ -30,11 +30,13 @@ /** - * compare two sockaddrs + * Compare two sockaddrs * @param addr1 first address to compare * @param addr2 second address to compare - * @cmpport if not zero, also compare the port - * @return 0 if both addriesses are equal + * @param cmpport if not zero, also compare the port + * @return 0 if both addriesses are equal, otherwise a value grater + * or less than zero, depending of the result + * * Currently there are there are only AF_INET and AF_INET6 * suppoorted */ @@ -77,9 +79,7 @@ int sock_cmpaddr(const struct sockaddr *addr1, const struct sockaddr *addr2,int return -1; } - return memcmp(s1,s2,slen); - }