prevent warnings in proxymain

This commit is contained in:
z3APA3A 2019-01-25 23:40:35 +03:00
parent 5ee553e9a9
commit 09507a2fe9
2 changed files with 3 additions and 3 deletions

View File

@ -156,7 +156,7 @@ options for proxy-to-client (oc), proxy-to-server (os), proxy listening (ol), co
Options like TCP_CORK, TCP_NODELAY, TCP_DEFER_ACCEPT, TCP_QUICKACK, TCP_TIMESTAMPS, USE_TCP_FASTOPEN, SO_REUSEADDR, SO_REUSEPORT, SO_PORT_SCALABILITY, SO_REUSE_UNICASTPORT, SO_KEEPALIVE, SO_DONTROUTE may be supported depending on OS.
.br
.B -DiINTERFACE, -DeINTERFACE
bind internal interface / external inteface to given INTERFACE (e.g. eth0) if SO_BINDTODEVICE supported by system
bind internal interface / external inteface to given INTERFACE (e.g. eth0) if SO_BINDTODEVICE supported by system. You may need to run as root or to have CAP_NET_RAW capability in order to bind to interface, depending on system.
.br
Also, all options mentioned for
.BR proxy (8)

View File

@ -44,7 +44,7 @@ void * threadfunc (void *p) {
continue;
}
#endif
if(socksendto(param->remsock, (struct sockaddr*)&param->sinsr, "C", 1, CONNBACK_TO) != 1){
if(socksendto(param->remsock, (struct sockaddr*)&param->sinsr, (unsigned char *)"C", 1, CONNBACK_TO) != 1){
param->srv->logfunc(param, (unsigned char *)"Connect back sending command failed");
so._closesocket(param->remsock);
param->remsock = INVALID_SOCKET;
@ -686,7 +686,7 @@ int MODULEMAINFUNC (int argc, char** argv){
usleep(SLEEPTIME);
continue;
}
if(sockrecvfrom(new_sock,(struct sockaddr*)&defparam.sincr,(char *)buf,1,60) != 1 || *buf!='C') {
if(sockrecvfrom(new_sock,(struct sockaddr*)&defparam.sincr,buf,1,60) != 1 || *buf!='C') {
so._closesocket(new_sock);
new_sock = INVALID_SOCKET;
usleep(SLEEPTIME);