ctdb-common: Protocol argument must be in host order for socket() call
[samba.git] / ctdb / common / system_common.c
index e11bcb2344096b5c130650d3c21a45c57a3968c4..a80189cd6c88cd46a0b42b8eb089f7583199c59c 100644 (file)
@@ -90,7 +90,7 @@ char *ctdb_sys_find_ifname(ctdb_sock_addr *addr)
        struct ifconf ifc;
        char *ptr;
 
-       s = socket(AF_INET, SOCK_RAW, htons(IPPROTO_RAW));
+       s = socket(AF_INET, SOCK_RAW, IPPROTO_RAW);
        if (s == -1) {
                DEBUG(DEBUG_CRIT,(__location__ " failed to open raw socket (%s)\n",
                         strerror(errno)));