diff --git a/src/cas/generic/casClient.cc b/src/cas/generic/casClient.cc index e9ecfce79..09c1a5f5f 100644 --- a/src/cas/generic/casClient.cc +++ b/src/cas/generic/casClient.cc @@ -180,7 +180,8 @@ casClient::~casClient () // void casClient::show (unsigned level) const { - printf ("casClient at %p\n", this); + printf ( "casClient at %p\n", + static_cast ( this ) ); this->casCoreClient::show (level); this->inBuf::show (level); this->outBuf::show (level); diff --git a/src/cas/generic/casCtx.cc b/src/cas/generic/casCtx.cc index e1b466cd3..e14a0ce58 100644 --- a/src/cas/generic/casCtx.cc +++ b/src/cas/generic/casCtx.cc @@ -6,14 +6,21 @@ // void casCtx::show (unsigned level) const { - printf ("casCtx at %p\n", this); + printf ( "casCtx at %p\n", + static_cast ( this ) ); if (level >= 3u) { - printf ("\tpMsg = %p\n", &this->msg); - printf ("\tpData = %p\n", pData); - printf ("\tpCAS = %p\n", pCAS); - printf ("\tpClient = %p\n", pClient); - printf ("\tpChannel = %p\n", pChannel); - printf ("\tpPV = %p\n", pPV); + printf ("\tpMsg = %p\n", + static_cast ( &this->msg ) ); + printf ("\tpData = %p\n", + static_cast ( pData ) ); + printf ("\tpCAS = %p\n", + static_cast ( pCAS ) ); + printf ("\tpClient = %p\n", + static_cast ( pClient ) ); + printf ("\tpChannel = %p\n", + static_cast ( pChannel ) ); + printf ("\tpPV = %p\n", + static_cast ( pPV ) ); } } diff --git a/src/cas/generic/casDGClient.cc b/src/cas/generic/casDGClient.cc index c6257b2a9..101505901 100644 --- a/src/cas/generic/casDGClient.cc +++ b/src/cas/generic/casDGClient.cc @@ -71,7 +71,8 @@ void casDGClient::destroy() // void casDGClient::show (unsigned level) const { - printf("casDGClient at %p\n", this); + printf ( "casDGClient at %p\n", + static_cast ( this ) ); if (level>=1u) { char buf[64]; this->clientHostName (buf, sizeof(buf)); diff --git a/src/cas/generic/casEventSys.cc b/src/cas/generic/casEventSys.cc index 7f4f08edd..e13a58cc5 100644 --- a/src/cas/generic/casEventSys.cc +++ b/src/cas/generic/casEventSys.cc @@ -44,7 +44,8 @@ // void casEventSys::show(unsigned level) const { - printf ("casEventSys at %p\n", this); + printf ( "casEventSys at %p\n", + static_cast ( this ) ); if (level>=1u) { printf ("\tnumEventBlocks = %u, maxLogEntries = %u\n", this->numEventBlocks, this->maxLogEntries); diff --git a/src/cas/generic/casStrmClient.cc b/src/cas/generic/casStrmClient.cc index 715f54cf7..ceee5c2d6 100644 --- a/src/cas/generic/casStrmClient.cc +++ b/src/cas/generic/casStrmClient.cc @@ -188,7 +188,8 @@ inline casClientMon *caServerI::resIdToClientMon (const caResId &idIn) void casStrmClient::show (unsigned level) const { this->casClient::show (level); - printf ("casStrmClient at %p\n", this); + printf ( "casStrmClient at %p\n", + static_cast ( this ) ); if (level > 1u) { printf ("\tuser %s at %s\n", this->pUserName, this->pHostName); } diff --git a/src/cas/generic/st/casDGIntfOS.cc b/src/cas/generic/st/casDGIntfOS.cc index a77c3e39b..a7e053794 100644 --- a/src/cas/generic/st/casDGIntfOS.cc +++ b/src/cas/generic/st/casDGIntfOS.cc @@ -159,7 +159,8 @@ const char *casDGEvWakeup::name() const // void casDGEvWakeup::show(unsigned level) const { - printf ("casDGEvWakeup at %p {\n", this); + printf ( "casDGEvWakeup at %p {\n", + static_cast ( this ) ); this->osiTimer::show(level); printf ("}\n"); } @@ -214,7 +215,8 @@ const char *casDGIOWakeup::name() const // void casDGIOWakeup::show(unsigned level) const { - printf ("casDGIOWakeup at %p {\n", this); + printf ( "casDGIOWakeup at %p {\n", + static_cast ( this ) ); this->osiTimer::show(level); printf ("}\n"); } @@ -332,8 +334,9 @@ void casDGIntfOS::eventFlush() // void casDGIntfOS::show(unsigned level) const { - printf ("casDGIntfOS at %p\n", this); - if (this->pRdReg) { + printf ( "casDGIntfOS at %p\n", + static_cast ( this ) ); + if (this->pRdReg) { this->pRdReg->show (level); } if (this->pWtReg) { @@ -398,7 +401,8 @@ casDGBCastReadReg::~casDGBCastReadReg() void casDGBCastReadReg::show(unsigned level) const { this->fdReg::show(level); - printf("casDGBCastReadReg at %p\n", this); + printf ( "casDGBCastReadReg at %p\n", + static_cast ( this ) ); } // @@ -428,7 +432,8 @@ void casDGWriteReg::callBack() void casDGWriteReg::show(unsigned level) const { this->fdReg::show (level); - printf ("casDGWriteReg: at %p\n", this); + printf ( "casDGWriteReg: at %p\n", + static_cast ( this ) ); } // diff --git a/src/cas/generic/st/casStreamOS.cc b/src/cas/generic/st/casStreamOS.cc index ac6468319..2d7806870 100644 --- a/src/cas/generic/st/casStreamOS.cc +++ b/src/cas/generic/st/casStreamOS.cc @@ -21,14 +21,12 @@ // class casStreamReadReg : public fdReg { public: - inline casStreamReadReg (casStreamOS &osIn); - inline ~casStreamReadReg (); - - void show (unsigned level) const; + inline casStreamReadReg (casStreamOS &osIn); + inline ~casStreamReadReg (); + void show (unsigned level) const; private: - casStreamOS &os; - - void callBack (); + casStreamOS &os; + void callBack (); }; // @@ -38,11 +36,11 @@ inline casStreamReadReg::casStreamReadReg (casStreamOS &osIn) : fdReg (osIn.getFD(), fdrRead), os (osIn) { # if defined(DEBUG) - printf ("Read on %d\n", this->os.getFD()); - printf ("Recv backlog %u\n", - this->os.inBuf::bytesPresent()); - printf ("Send backlog %u\n", - this->os.outBuf::bytesPresent()); + printf ("Read on %d\n", this->os.getFD()); + printf ("Recv backlog %u\n", + this->os.inBuf::bytesPresent()); + printf ("Send backlog %u\n", + this->os.outBuf::bytesPresent()); # endif } @@ -148,7 +146,8 @@ const char *casStreamEvWakeup::name() const // void casStreamEvWakeup::show(unsigned level) const { - printf ("casStreamEvWakeup at %p {\n", this); + printf ( "casStreamEvWakeup at %p {\n", + static_cast ( this ) ); this->osiTimer::show(level); printf ("}\n"); } @@ -218,7 +217,8 @@ const char *casStreamIOWakeup::name() const // void casStreamIOWakeup::show(unsigned level) const { - printf ("casStreamIOWakeup at %p {\n", this); + printf ( "casStreamIOWakeup at %p {\n", + static_cast ( this ) ); this->osiTimer::show(level); printf ("}\n"); } @@ -385,7 +385,8 @@ casStreamOS::~casStreamOS() void casStreamOS::show(unsigned level) const { this->casStrmClient::show(level); - printf("casStreamOS at %p\n", this); + printf("casStreamOS at %p\n", + static_cast ( this ) ); printf("\tsendBlocked = %d\n", this->sendBlocked); if (this->pWtReg) { this->pWtReg->show(level); @@ -407,7 +408,8 @@ void casStreamOS::show(unsigned level) const void casStreamReadReg::show(unsigned level) const { this->fdReg::show(level); - printf ("casStreamReadReg at %p\n", this); + printf ( "casStreamReadReg at %p\n", + static_cast ( this ) ); } // @@ -479,7 +481,8 @@ void casStreamOS::sendBlockSignal() void casStreamWriteReg::show(unsigned level) const { this->fdReg::show (level); - printf ("casStreamWriteReg at %p\n", this); + printf ( "casStreamWriteReg at %p\n", + static_cast ( this ) ); } // diff --git a/src/cas/io/bsdSocket/caServerIO.cc b/src/cas/io/bsdSocket/caServerIO.cc index f5049c0f7..6b165959a 100644 --- a/src/cas/io/bsdSocket/caServerIO.cc +++ b/src/cas/io/bsdSocket/caServerIO.cc @@ -140,7 +140,8 @@ inline void caServerIO::staticInit() // void caServerIO::show (unsigned /* level */) const { - printf ("caServerIO at %p\n", this); + printf ( "caServerIO at %p\n", + static_cast ( this ) ); } // diff --git a/src/cas/io/bsdSocket/casDGIntfIO.cc b/src/cas/io/bsdSocket/casDGIntfIO.cc index 0f5664ab2..f89d6b266 100644 --- a/src/cas/io/bsdSocket/casDGIntfIO.cc +++ b/src/cas/io/bsdSocket/casDGIntfIO.cc @@ -244,7 +244,8 @@ casDGIntfIO::~casDGIntfIO() // void casDGIntfIO::show (unsigned level) const { - printf ("casDGIntfIO at %p\n", this); + printf ( "casDGIntfIO at %p\n", + static_cast ( this ) ); printChannelAccessAddressList (&this->beaconAddrList); this->casDGClient::show (level); } diff --git a/src/cas/io/bsdSocket/casStreamIO.cc b/src/cas/io/bsdSocket/casStreamIO.cc index a4a81fc73..8551987d5 100644 --- a/src/cas/io/bsdSocket/casStreamIO.cc +++ b/src/cas/io/bsdSocket/casStreamIO.cc @@ -5,6 +5,9 @@ // // // $Log$ +// Revision 1.20 2000/04/28 02:23:34 jhill +// many, many changes +// // Revision 1.19 1999/09/02 21:50:28 jhill // o changed UDP to non-blocking IO // o cleaned up (consolodated) UDP interface class structure @@ -234,7 +237,8 @@ inBuf::fillCondition casStreamIO::osdRecv (char *pInBuf, bufSizeT nBytes, // void casStreamIO::osdShow (unsigned level) const { - printf ("casStreamIO at %p\n", this); + printf ( "casStreamIO at %p\n", + static_cast ( this ) ); if (level>1u) { char buf[64]; ipAddrToA(&this->addr, buf, sizeof(buf)); diff --git a/src/libCom/fdmgr/fdManager.cpp b/src/libCom/fdmgr/fdManager.cpp index 0c1a202f2..ac9c26a91 100644 --- a/src/libCom/fdmgr/fdManager.cpp +++ b/src/libCom/fdmgr/fdManager.cpp @@ -296,12 +296,13 @@ epicsShareFunc void fdReg::show(unsigned level) const // // fdRegId::show() // -void fdRegId::show(unsigned level) const +void fdRegId::show ( unsigned level ) const { - printf ("fdRegId at %p\n", this); - if (level>1u) { - printf ("\tfd = %d, type = %d\n", - this->fd, this->type); + printf ( "fdRegId at %p\n", + static_cast ( this ) ); + if ( level > 1u ) { + printf ( "\tfd = %d, type = %d\n", + this->fd, this->type ); } } diff --git a/src/libCom/logClient/logClient.c b/src/libCom/logClient/logClient.c index 6c59fe82b..1400fd0d9 100644 --- a/src/libCom/logClient/logClient.c +++ b/src/libCom/logClient/logClient.c @@ -665,7 +665,7 @@ epicsShareFunc void epicsShareAPI logClientShow (logClientId id, unsigned level) if (level>1) { printf ("iocLogClient: address=%p, sock=%s, connect tries=%u, connect cycles = %u\n", - pClient, pClient->sock==INVALID_SOCKET?"INVALID":"OK", + (void *) pClient, pClient->sock==INVALID_SOCKET?"INVALID":"OK", pClient->connectTries, pClient->connectCount); } } diff --git a/src/libCom/misc/ipAddrToAsciiAsynchronous.cpp b/src/libCom/misc/ipAddrToAsciiAsynchronous.cpp index 5d7215a6c..f89d7c0a7 100644 --- a/src/libCom/misc/ipAddrToAsciiAsynchronous.cpp +++ b/src/libCom/misc/ipAddrToAsciiAsynchronous.cpp @@ -95,7 +95,7 @@ void ipAddrToAsciiEngine::show ( unsigned level ) const { this->mutex.lock (); printf ( "ipAddrToAsciiEngine at %p with %u requests pendingh\n", - this, this->labor.count () ); + static_cast (this), this->labor.count () ); if ( level > 0u ) { tsDLIterConstBD < ipAddrToAsciiAsynchronous > pItem = this->labor.firstIter (); while ( pItem.valid () ) { @@ -163,7 +163,8 @@ void ipAddrToAsciiAsynchronous::show ( unsigned level ) const sockAddrToA ( &this->addr.sa, ipAddr, sizeof ( ipAddr ) ); printf ( "ipAddrToAsciiAsynchronous for address %s\n", ipAddr ); if ( level > 0u ) { - printf ( "\tidentifier %u, engine %p\n", this->id, this->pEngine ); + printf ( "\tidentifier %u, engine %p\n", this->id, + static_cast (this->pEngine) ); } ipAddrToAsciiEngine::mutex.unlock (); } diff --git a/src/libCom/timer/osiTimer.cpp b/src/libCom/timer/osiTimer.cpp index 49da45eff..a323e069b 100644 --- a/src/libCom/timer/osiTimer.cpp +++ b/src/libCom/timer/osiTimer.cpp @@ -353,7 +353,7 @@ void osiTimer::show (unsigned level) const { epicsTime cur = epicsTime::getCurrent (); printf ("osiTimer at %p for \"%s\" with again = %d\n", - this, this->name(), this->again()); + static_cast (this), this->name(), this->again()); if (level>=1u) { double delay = this->exp - cur; printf ("\tdelay to expire = %f, state = %d\n", diff --git a/src/libCom/timer/timerQueueThreaded.cpp b/src/libCom/timer/timerQueueThreaded.cpp index 5305aa005..71bab0113 100644 --- a/src/libCom/timer/timerQueueThreaded.cpp +++ b/src/libCom/timer/timerQueueThreaded.cpp @@ -99,7 +99,8 @@ void timerQueueThreaded::reschedule () void timerQueueThreaded::show ( unsigned int level ) const { - printf ( "EPICS threaded timer queue at %p\n", this ); + printf ( "EPICS threaded timer queue at %p\n", + static_cast ( this ) ); if ( level >=1u ) { this->queue.show ( level - 1u ); printf ( "reschedule event\n" );