Hi,<div><br></div><div>I have tried compiling msl_test.c on Freebsd </div><div><br></div><div><div> g++ -o msl_test msl_test.c </div><div>In file included from msl_test.c:53:</div><div>msl_test_bsd.c: In function `void* bpfWalkInit(void*, int*)':</div>
<div>msl_test_bsd.c:45: error: invalid conversion from `void*' to `bpf_hdr*'</div><div>msl_test_bsd.c:46: error: pointer of type `void *' used in arithmetic</div><div>msl_test_bsd.c:46: error: invalid conversion from `void*' to `char*'</div>
<div>msl_test_bsd.c: In function `void* bpfWalkNext(int*)':</div><div>msl_test_bsd.c:61: error: invalid conversion from `void*' to `bpf_hdr*'</div><div>msl_test_bsd.c:68: error: pointer of type `void *' used in arithmetic</div>
<div>msl_test_bsd.c:69: error: pointer of type `void *' used in arithmetic</div><div>msl_test_bsd.c:73: error: invalid conversion from `void*' to `bpf_hdr*'</div><div>msl_test_bsd.c:78: error: pointer of type `void *' used in arithmetic</div>
<div>msl_test_bsd.c:78: error: invalid conversion from `void*' to `char*'</div><div>msl_test_bsd.c: In function `void msl_probe(void*, int)':</div><div>msl_test_bsd.c:203: error: invalid conversion from `void*' to `char*'</div>
<div>msl_test_bsd.c:203: error: invalid conversion from `void*' to `char*'</div><div>msl_test.c: In function `void breakupPacket(void*, ether_header**, ip**, tcphdr**)':</div><div>msl_test.c:166: error: pointer of type `void *' used in arithmetic</div>
<div>msl_test.c:170: error: pointer of type `void *' used in arithmetic</div><div>msl_test.c: In function `int createTCPsession(sockaddr_in)':</div><div>msl_test.c:225: error: invalid conversion from `int*' to `socklen_t*'</div>
<div>msl_test.c:225: error: initializing argument 3 of `int getsockname(int, sockaddr*, socklen_t*)'</div></div><div><br></div><div><br></div><div>and in ubuntu and also debian</div><div><br></div><div><div>g++ -o msl_test msl_test.c </div>
<div>In file included from msl_test.c:51:</div><div>msl_test_linux.c: In function ‘int raw_open(char*)’:</div><div>msl_test_linux.c:138: error: invalid conversion from ‘unsigned char*’ to ‘char*’</div><div>msl_test_linux.c:138: error: initializing argument 1 of ‘char* strncpy(char*, const char*, size_t)’</div>
<div>msl_test_linux.c: In function ‘void* find_our_packet(int*)’:</div><div>msl_test_linux.c:169: error: invalid conversion from ‘int*’ to ‘socklen_t*’</div><div>msl_test_linux.c:169: error: initializing argument 6 of ‘ssize_t recvfrom(int, void*, size_t, int, sockaddr*, socklen_t*)’</div>
<div>msl_test.c: In function ‘void breakupPacket(void*, ether_header**, ip**, tcphdr**)’:</div><div>msl_test.c:166: warning: pointer of type ‘void *’ used in arithmetic</div><div>msl_test.c:170: warning: pointer of type ‘void *’ used in arithmetic</div>
<div>msl_test.c: In function ‘int createTCPsession(sockaddr_in)’:</div><div>msl_test.c:225: error: invalid conversion from ‘int*’ to ‘socklen_t*’</div><div>msl_test.c:225: error: initializing argument 3 of ‘int getsockname(int, sockaddr*, socklen_t*)’</div>
</div><div><br></div><div><br></div><div>What am I missing, any help appreciated ?</div><div><br></div>