Ack, Should we give print the fd also?
Thanks, Mathi. ----- [email protected] wrote: > osaf/libs/agents/infrastructure/rda/rda_papi.c | 7 ++++++- > 1 files changed, 6 insertions(+), 1 deletions(-) > > > If recv() fails due to any other reason than EAGAIN or EINTR, does > osaf_abort() to generate a core dump. > > diff --git a/osaf/libs/agents/infrastructure/rda/rda_papi.c > b/osaf/libs/agents/infrastructure/rda/rda_papi.c > --- a/osaf/libs/agents/infrastructure/rda/rda_papi.c > +++ b/osaf/libs/agents/infrastructure/rda/rda_papi.c > @@ -37,6 +37,7 @@ > #include <sched.h> > #include "logtrace.h" > #include "osaf_poll.h" > +#include "osaf_utility.h" > > /* > ** Global data > @@ -112,6 +113,7 @@ static uint32_t rda_callback_task(RDA_CA > rc = rda_callback_req(rda_callback_cb->sockfd); > if (rc != PCSRDA_RC_SUCCESS) { > rda_disconnect(rda_callback_cb->sockfd); > + rda_callback_cb->sockfd = -1; > continue; > } > > @@ -678,7 +680,10 @@ static uint32_t rda_read_msg(int sockfd, > */ > msg_size = recv(sockfd, msg, size, 0); > if (msg_size < 0) { > - LOG_ER("recv: PCSRDA_RC_IPC_RECV_FAILED: rc=%d-%s\n", errno, > strerror(errno)); > + if (errno != EINTR && errno != EWOULDBLOCK) { > + LOG_ER("recv: PCSRDA_RC_IPC_RECV_FAILED: rc=%d-%s\n", > errno, > strerror(errno)); > + osaf_abort(msg_size); > + } > return PCSRDA_RC_IPC_RECV_FAILED; > } ------------------------------------------------------------------------------ Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft _______________________________________________ Opensaf-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/opensaf-devel
