From c3e162447833153a2e546d82457d1947e26efc2f Mon Sep 17 00:00:00 2001 From: Jeff Hill Date: Tue, 7 Jan 2003 15:59:51 +0000 Subject: [PATCH] cosmetic --- src/ca/iocinf.cpp | 2 +- src/cas/generic/outBuf.cc | 2 +- src/cas/io/bsdSocket/casDGIntfIO.cc | 6 +++--- src/cas/io/bsdSocket/casIntfIO.cc | 18 ++++++++++-------- 4 files changed, 15 insertions(+), 13 deletions(-) diff --git a/src/ca/iocinf.cpp b/src/ca/iocinf.cpp index ad265b3a8..6ed6c6cc9 100644 --- a/src/ca/iocinf.cpp +++ b/src/ca/iocinf.cpp @@ -124,7 +124,7 @@ extern "C" void epicsShareAPI removeDuplicateAddresses while ( (pRawNode = ellGet ( pSrcList ) ) ) { assert ( offsetof (osiSockAddrNode, node) == 0 ); - osiSockAddrNode *pNode = reinterpret_cast ( pRawNode ); + osiSockAddrNode *pNode = reinterpret_cast ( pRawNode ); osiSockAddrNode *pTmpNode; if ( pNode->addr.sa.sa_family == AF_INET ) { diff --git a/src/cas/generic/outBuf.cc b/src/cas/generic/outBuf.cc index 96c3637b9..0346e60dc 100644 --- a/src/cas/generic/outBuf.cc +++ b/src/cas/generic/outBuf.cc @@ -126,7 +126,7 @@ caStatus outBuf::copyInHeader ( ca_uint16_t response, ca_uint32_t payloadSize, else { pHdr->m_postsize = epicsHTON16 ( 0xffff ); pHdr->m_count = epicsHTON16 ( 0 ); - ca_uint32_t * pLW = reinterpret_cast ( pHdr + 1 ); + ca_uint32_t * pLW = reinterpret_cast < ca_uint32_t * > ( pHdr + 1 ); pLW[0] = epicsHTON32 ( alignedPayloadSize ); pLW[1] = epicsHTON32 ( nElem ); pPayload = reinterpret_cast < char * > ( pLW + 2 ); diff --git a/src/cas/io/bsdSocket/casDGIntfIO.cc b/src/cas/io/bsdSocket/casDGIntfIO.cc index b3f29c02b..92cc489cf 100644 --- a/src/cas/io/bsdSocket/casDGIntfIO.cc +++ b/src/cas/io/bsdSocket/casDGIntfIO.cc @@ -30,12 +30,12 @@ static void forcePort (ELLLIST *pList, unsigned short port) { osiSockAddrNode *pNode; - pNode = reinterpret_cast (ellFirst ( pList )); + pNode = reinterpret_cast < osiSockAddrNode * > ( ellFirst ( pList ) ); while ( pNode ) { if ( pNode->addr.sa.sa_family == AF_INET ) { pNode->addr.ia.sin_port = htons (port); } - pNode = reinterpret_cast (ellNext ( &pNode->node )); + pNode = reinterpret_cast < osiSockAddrNode * > ( ellNext ( &pNode->node ) ); } } @@ -113,7 +113,7 @@ casDGIntfIO::casDGIntfIO ( caServerI & serverIn, clientBufMemoryManager & memMgr socket_close (this->sock); throw S_cas_noInterface; } - pAddr = reinterpret_cast (ellFirst (&BCastAddrList)); + pAddr = reinterpret_cast < osiSockAddrNode * > ( ellFirst ( &BCastAddrList ) ); serverBCastAddr.ia = pAddr->addr.ia; serverBCastAddr.ia.sin_port = htons (this->dgPort); diff --git a/src/cas/io/bsdSocket/casIntfIO.cc b/src/cas/io/bsdSocket/casIntfIO.cc index fcc411979..76df0a198 100644 --- a/src/cas/io/bsdSocket/casIntfIO.cc +++ b/src/cas/io/bsdSocket/casIntfIO.cc @@ -69,9 +69,9 @@ casIntfIO::casIntfIO (const caNetAddr &addrIn) : } # endif - status = bind(this->sock, + status = bind ( this->sock, reinterpret_cast (&this->addr), - sizeof(this->addr)); + sizeof(this->addr) ); if (status<0) { if (SOCKERRNO == SOCK_EADDRINUSE) { // @@ -80,9 +80,10 @@ casIntfIO::casIntfIO (const caNetAddr &addrIn) : // work correctly) // this->addr.sin_port = ntohs (0); - status = bind(this->sock, - reinterpret_cast (&this->addr), - sizeof(this->addr)); + status = bind( + this->sock, + reinterpret_cast (&this->addr), + sizeof(this->addr) ); } if (status<0) { char buf[64]; @@ -103,9 +104,10 @@ casIntfIO::casIntfIO (const caNetAddr &addrIn) : } addrSize = ( osiSocklen_t ) sizeof (this->addr); - status = getsockname (this->sock, - reinterpret_cast (&this->addr) - , &addrSize); + status = getsockname ( + this->sock, + reinterpret_cast ( &this->addr ), + &addrSize ); if (status) { errlogPrintf("CAS: getsockname() error %s\n", SOCKERRSTR(SOCKERRNO));