version 1.23.2.4, 2015/01/21 00:37:04
|
version 1.23.2.6, 2015/01/21 20:58:07
|
Line 352 rpc_pkt_Receive(int sock, int type, sockaddr_t * __res
|
Line 352 rpc_pkt_Receive(int sock, int type, sockaddr_t * __res
|
ret = rpc_Read(sock, type, !estlen ? MSG_PEEK : 0, NULL, buf, blen); |
ret = rpc_Read(sock, type, !estlen ? MSG_PEEK : 0, NULL, buf, blen); |
else if (type == SOCK_EXT) { |
else if (type == SOCK_EXT) { |
ret = rpc_Read(sock, type, 0, NULL, buf, blen); |
ret = rpc_Read(sock, type, 0, NULL, buf, blen); |
if (ret > 0) | if (estlen) /* hack for skip sanity checks */ |
estlen = ret; | ret += sizeof(struct tagRPCCall); |
} else if (type == SOCK_BPF) { |
} else if (type == SOCK_BPF) { |
ret = rpc_Read(sock, type, 0, sa, AIT_GET_BUF(pkt), AIT_LEN(pkt)); |
ret = rpc_Read(sock, type, 0, sa, AIT_GET_BUF(pkt), AIT_LEN(pkt)); |
if (ret > 0) |
if (ret > 0) |
Line 370 rpc_pkt_Receive(int sock, int type, sockaddr_t * __res
|
Line 370 rpc_pkt_Receive(int sock, int type, sockaddr_t * __res
|
} |
} |
|
|
/* check for loop request */ |
/* check for loop request */ |
if (!(rpc->call_io & RPC_ACK)) | if (!estlen && !(rpc->call_io & RPC_ACK)) |
continue; |
continue; |
|
|
/* check for response from known address */ |
/* check for response from known address */ |
Line 379 rpc_pkt_Receive(int sock, int type, sockaddr_t * __res
|
Line 379 rpc_pkt_Receive(int sock, int type, sockaddr_t * __res
|
estlen = ntohl(rpc->call_len); |
estlen = ntohl(rpc->call_len); |
if (estlen > AIT_LEN(pkt)) |
if (estlen > AIT_LEN(pkt)) |
AIT_RE_BUF(pkt, estlen); |
AIT_RE_BUF(pkt, estlen); |
|
blen = estlen; |
buf = AIT_GET_BUF(pkt); |
buf = AIT_GET_BUF(pkt); |
|
|
|
if (type == SOCK_EXT) { |
|
blen -= sizeof(struct tagRPCCall); |
|
buf += sizeof(struct tagRPCCall); |
|
} |
|
|
rpc = (struct tagRPCCall*) buf; |
rpc = (struct tagRPCCall*) buf; |
blen = estlen; |
|
continue; |
continue; |
} |
} |
|
|
Line 563 rpc_cli_execCall(rpc_cli_t *cli, int noreply, u_short
|
Line 569 rpc_cli_execCall(rpc_cli_t *cli, int noreply, u_short
|
rpc_SetErr(EINVAL, "Can`t execute call because parameter is null or invalid!"); |
rpc_SetErr(EINVAL, "Can`t execute call because parameter is null or invalid!"); |
return -1; |
return -1; |
} else { |
} else { |
if (cli->cli_id == SOCK_STREAM) | if (cli->cli_id == SOCK_STREAM || cli->cli_id == SOCK_EXT) |
type = cli->cli_id; |
type = cli->cli_id; |
buf = AIT_GET_BUF(&cli->cli_buf); |
buf = AIT_GET_BUF(&cli->cli_buf); |
} |
} |