--- libaitrpc/src/aitrpc.c 2015/07/02 22:28:14 1.19 +++ libaitrpc/src/aitrpc.c 2015/07/22 20:01:46 1.20 @@ -3,7 +3,7 @@ * by Michael Pounov * * $Author: misho $ -* $Id: aitrpc.c,v 1.19 2015/07/02 22:28:14 misho Exp $ +* $Id: aitrpc.c,v 1.20 2015/07/22 20:01:46 misho Exp $ * ************************************************************************** The ELWIX and AITNET software is distributed under the following @@ -151,7 +151,7 @@ try2read: pfd.events = POLLIN | POLLPRI; memset(buf, 0, blen); memset(&sa2, 0, sizeof sa2); - salen = sa2.ss.ss_len = sizeof(sockaddr_t); + salen = sa2.ss.ss_len = (u_char) MIN(sizeof(sockaddr_t), 0xff); if ((ret = poll(&pfd, 1, DEF_RPC_TIMEOUT * 1000)) < 1 || pfd.revents & (POLLERR | POLLHUP | POLLNVAL)) { if (ret)