--- libaitrpc/src/cli.c 2013/01/17 16:33:57 1.13.4.1 +++ libaitrpc/src/cli.c 2013/01/17 17:01:51 1.13.4.3 @@ -3,7 +3,7 @@ * by Michael Pounov * * $Author: misho $ -* $Id: cli.c,v 1.13.4.1 2013/01/17 16:33:57 misho Exp $ +* $Id: cli.c,v 1.13.4.3 2013/01/17 17:01:51 misho Exp $ * ************************************************************************** The ELWIX and AITNET software is distributed under the following @@ -375,9 +375,11 @@ rpc_cli_execCall(rpc_cli_t *cli, int noreply, u_short memset(buf, 0, AIT_LEN(&cli->cli_buf)); if (cli->cli_id == SOCK_STREAM) ret = recv(cli->cli_sock, buf, AIT_LEN(&cli->cli_buf), 0); - else + else { + salen = sa.ss.ss_len = sizeof(sockaddr_t); ret = recvfrom(cli->cli_sock, buf, AIT_LEN(&cli->cli_buf), 0, &sa.sa, &salen); + } if (ret < 1) { if (ret) { if (errno == EAGAIN)