Handle SOCK_EINTR without generating warnings.

This commit is contained in:
Andrew Johnson
2009-05-08 21:50:37 +00:00
parent 6c26a81d97
commit f1b1c6d105

View File

@@ -3,8 +3,7 @@
* National Laboratory.
* Copyright (c) 2002 The Regents of the University of California, as
* Operator of Los Alamos National Laboratory.
* EPICS BASE Versions 3.13.7
* and higher are distributed subject to a Software License Agreement found
* EPICS BASE is distributed subject to a Software License Agreement found
* in file LICENSE that is included with this distribution.
\*************************************************************************/
/*
@@ -222,13 +221,15 @@ void cast_server(void *pParm)
0,
(struct sockaddr *)&new_recv_addr,
&recv_addr_size);
if (status<0) {
char sockErrBuf[64];
epicsSocketConvertErrnoToString (
sockErrBuf, sizeof ( sockErrBuf ) );
epicsPrintf ("CAS: UDP recv error (errno=%s)\n",
sockErrBuf);
epicsThreadSleep(1.0);
if (status < 0) {
if (SOCKERRNO != SOCK_EINTR) {
char sockErrBuf[64];
epicsSocketConvertErrnoToString (
sockErrBuf, sizeof ( sockErrBuf ) );
epicsPrintf ("CAS: UDP recv error (errno=%s)\n",
sockErrBuf);
epicsThreadSleep(1.0);
}
}
else if (casudp_ctl == ctlRun) {
prsrv_cast_client->recv.cnt = (unsigned) status;