Return-Path: Delivered-To: apmail-geronimo-activemq-commits-archive@www.apache.org Received: (qmail 97377 invoked from network); 26 Jan 2007 21:12:02 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 26 Jan 2007 21:12:02 -0000 Received: (qmail 24791 invoked by uid 500); 26 Jan 2007 21:12:08 -0000 Delivered-To: apmail-geronimo-activemq-commits-archive@geronimo.apache.org Received: (qmail 24779 invoked by uid 500); 26 Jan 2007 21:12:08 -0000 Mailing-List: contact activemq-commits-help@geronimo.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: activemq-dev@geronimo.apache.org Delivered-To: mailing list activemq-commits@geronimo.apache.org Received: (qmail 24770 invoked by uid 99); 26 Jan 2007 21:12:08 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 26 Jan 2007 13:12:08 -0800 X-ASF-Spam-Status: No, hits=-9.4 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [140.211.11.3] (HELO eris.apache.org) (140.211.11.3) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 26 Jan 2007 13:12:00 -0800 Received: by eris.apache.org (Postfix, from userid 65534) id 637691A981D; Fri, 26 Jan 2007 13:11:40 -0800 (PST) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r500349 [2/2] - in /incubator/activemq/activemq-cpp/trunk/activemq-cpp/src: main/activemq/concurrent/ main/activemq/connector/openwire/marshal/ main/activemq/connector/openwire/utils/ main/activemq/connector/stomp/ main/activemq/connector/s... Date: Fri, 26 Jan 2007 21:11:37 -0000 To: activemq-commits@geronimo.apache.org From: nmittler@apache.org X-Mailer: svnmailer-1.1.0 Message-Id: <20070126211140.637691A981D@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/ServerSocket.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/ServerSocket.cpp?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/ServerSocket.cpp (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/ServerSocket.cpp Fri Jan 26 13:11:34 2007 @@ -96,7 +96,9 @@ } //////////////////////////////////////////////////////////////////////////////// -void ServerSocket::bind( const char* host, int port, int backlog ) throw ( SocketException ) +void ServerSocket::bind( const char* host, + int port, + int backlog ) throw ( SocketException ) { if(isBound()) { throw SocketException ( __FILE__, __LINE__, @@ -159,7 +161,7 @@ throw SocketException ( __FILE__, __LINE__, "ServerSocket::bind - %s", SocketError::getErrorString().c_str() ); } - status = ::listen( socketHandle, backlog ); + status = ::listen( socketHandle, (int)backlog ); if( status < 0 ) { close(); throw SocketException( __FILE__, __LINE__, SocketError::getErrorString().c_str() ); @@ -187,7 +189,7 @@ } //////////////////////////////////////////////////////////////////////////////// -Socket* ServerSocket::accept () throw (SocketException) +Socket* ServerSocket::accept() throw (SocketException) { struct sockaddr_in temp; Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/ServerSocket.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/ServerSocket.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/ServerSocket.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/ServerSocket.h Fri Jan 26 13:11:34 2007 @@ -66,7 +66,9 @@ * @param port TCP port between 1..655535 * @param backlog Size of listen backlog. */ - virtual void bind( const char* host, int port, int backlog ) throw ( SocketException ); + virtual void bind( const char* host, + int port, + int backlog ) throw ( SocketException ); /** * Blocks until a client connects to the bound socket. Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/Socket.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/Socket.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/Socket.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/Socket.h Fri Jan 26 13:11:34 2007 @@ -48,7 +48,7 @@ public: - virtual ~Socket(void) {} + virtual ~Socket() {} /** * Connects to the specified destination. Closes this socket if @@ -57,7 +57,7 @@ * @param port The port of the server to connect to. * @throws IOException Thrown if a failure occurred in the connect. */ - virtual void connect( const char* host, const int port ) + virtual void connect( const char* host, int port ) throw(SocketException) = 0; /** @@ -90,7 +90,7 @@ * @param linger The linger time in seconds. If 0, linger is off. * @throws SocketException if the operation fails. */ - virtual void setSoLinger( const int linger ) throw( SocketException ) = 0; + virtual void setSoLinger( int linger ) throw( SocketException ) = 0; /** * Gets the keep alive flag. @@ -104,7 +104,7 @@ * @param keepAlive If true, enables the flag. * @throws SocketException if the operation fails. */ - virtual void setKeepAlive( const bool keepAlive ) throw( SocketException ) = 0; + virtual void setKeepAlive( bool keepAlive ) throw( SocketException ) = 0; /** * Gets the receive buffer size. @@ -118,7 +118,7 @@ * @param size Number of bytes to set the receive buffer to. * @throws SocketException if the operation fails. */ - virtual void setReceiveBufferSize( const int size ) throw( SocketException ) = 0; + virtual void setReceiveBufferSize( int size ) throw( SocketException ) = 0; /** * Gets the reuse address flag. @@ -132,7 +132,7 @@ * @param reuse If true, sets the flag. * @throws SocketException if the operation fails. */ - virtual void setReuseAddress( const bool reuse ) throw( SocketException ) = 0; + virtual void setReuseAddress( bool reuse ) throw( SocketException ) = 0; /** * Gets the send buffer size. @@ -146,7 +146,7 @@ * @param size The number of bytes to set the send buffer to. * @throws SocketException if the operation fails. */ - virtual void setSendBufferSize( const int size ) throw( SocketException ) = 0; + virtual void setSendBufferSize( int size ) throw( SocketException ) = 0; /** * Gets the timeout for socket operations. @@ -160,7 +160,7 @@ * @param timeout The timeout in milliseconds for socket operations.

* @throws SocketException Thrown if unable to set the information. */ - virtual void setSoTimeout( const int timeout ) throw( SocketException ) = 0; + virtual void setSoTimeout( int timeout ) throw( SocketException ) = 0; }; Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketFactory.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketFactory.cpp?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketFactory.cpp (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketFactory.cpp Fri Jan 26 13:11:34 2007 @@ -42,7 +42,7 @@ string dummy = uri; // Extract the port. - unsigned int portIx = dummy.find( ':' ); + std::size_t portIx = dummy.find( ':' ); if( portIx == string::npos ) { throw SocketException( __FILE__, __LINE__, Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketInputStream.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketInputStream.cpp?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketInputStream.cpp (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketInputStream.cpp Fri Jan 26 13:11:34 2007 @@ -61,7 +61,7 @@ } //////////////////////////////////////////////////////////////////////////////// -int SocketInputStream::available() const throw (activemq::io::IOException){ +std::size_t SocketInputStream::available() const throw (activemq::io::IOException){ // The windows version #if defined(HAVE_WINSOCK2_H) @@ -72,7 +72,7 @@ throw SocketException( __FILE__, __LINE__, "ioctlsocket failed" ); } - return (int)numBytes; + return (std::size_t)numBytes; #else // !defined(HAVE_WINSOCK2_H) @@ -80,7 +80,7 @@ // are available. #if defined(FIONREAD) - int numBytes = 0; + std::size_t numBytes = 0; if( ::ioctl (socket, FIONREAD, &numBytes) != -1 ){ return numBytes; } @@ -118,7 +118,7 @@ unsigned char SocketInputStream::read() throw (IOException){ unsigned char c; - int len = read( &c, 1 ); + std::size_t len = read( &c, 1 ); if( len != sizeof(c) ){ throw IOException( __FILE__, __LINE__, "activemq::io::SocketInputStream::read - failed reading a byte"); @@ -128,9 +128,10 @@ } //////////////////////////////////////////////////////////////////////////////// -int SocketInputStream::read( unsigned char* buffer, int bufferSize ) throw (IOException){ - - int len = ::recv(socket, (char*)buffer, bufferSize, 0); +std::size_t SocketInputStream::read( unsigned char* buffer, + std::size_t bufferSize ) throw (IOException) +{ + int len = ::recv(socket, (char*)buffer, (int)bufferSize, 0); // Check for a closed socket. if( len == 0 ){ @@ -161,7 +162,7 @@ } //////////////////////////////////////////////////////////////////////////////// -int SocketInputStream::skip( int num AMQCPP_UNUSED ) +std::size_t SocketInputStream::skip( std::size_t num AMQCPP_UNUSED ) throw ( io::IOException, exceptions::UnsupportedOperationException ) { throw exceptions::UnsupportedOperationException(__FILE__, __LINE__, "skip() method is not supported"); Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketInputStream.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketInputStream.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketInputStream.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketInputStream.h Fri Jan 26 13:11:34 2007 @@ -125,7 +125,7 @@ * @return The number of bytes currently available to * be read on the socket. */ - virtual int available() const throw (activemq::io::IOException); + virtual std::size_t available() const throw (activemq::io::IOException); /** * Reads a single byte from the buffer. If no data @@ -143,7 +143,9 @@ * @return The number of bytes read. * @throws IOException thrown if an error occurs. */ - virtual int read( unsigned char* buffer, int bufferSize ) throw (io::IOException); + virtual std::size_t read( unsigned char* buffer, + std::size_t bufferSize ) + throw (io::IOException); /** * Close - does nothing. It is the responsibility of the owner @@ -156,7 +158,9 @@ * Not supported. * @throws an UnsupportedOperationException. */ - virtual int skip( int num ) throw ( io::IOException, exceptions::UnsupportedOperationException ); + virtual std::size_t skip( std::size_t num ) + throw ( io::IOException, + exceptions::UnsupportedOperationException ); }; Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketOutputStream.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketOutputStream.cpp?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketOutputStream.cpp (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketOutputStream.cpp Fri Jan 26 13:11:34 2007 @@ -60,15 +60,15 @@ } //////////////////////////////////////////////////////////////////////////////// -void SocketOutputStream::write( const unsigned char* buffer, int len ) +void SocketOutputStream::write( const unsigned char* buffer, std::size_t len ) throw (IOException) { - int remaining = len; + std::size_t remaining = len; int sendOpts = AMQ_SEND_OPTS; if( debug ){ printf("SocketOutputStream:write(), numbytes:%d -", len); - for( int ix=0; ix 20 ){ printf("%c", c ); @@ -80,8 +80,8 @@ while( remaining > 0 ) { - int length = ::send( socket, (const char*)buffer, remaining, sendOpts ); - if( length < 0 ){ + std::size_t length = (size_t)::send( socket, (const char*)buffer, (int)remaining, sendOpts ); + if( length == -1 ){ throw IOException( __FILE__, __LINE__, "activemq::io::SocketOutputStream::write - %s", SocketError::getErrorString().c_str() ); } Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketOutputStream.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketOutputStream.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketOutputStream.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketOutputStream.h Fri Jan 26 13:11:34 2007 @@ -128,7 +128,8 @@ * @param len The number of bytes from the buffer to be written. * @throws IOException thrown if an error occurs. */ - virtual void write( const unsigned char* buffer, int len ) throw ( io::IOException ); + virtual void write( const unsigned char* buffer, + std::size_t len ) throw ( io::IOException ); /** * Flush - does nothing. Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/TcpSocket.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/TcpSocket.cpp?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/TcpSocket.cpp (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/TcpSocket.cpp Fri Jan 26 13:11:34 2007 @@ -241,7 +241,7 @@ } //////////////////////////////////////////////////////////////////////////////// -void TcpSocket::setSoLinger( const int dolinger ) throw( SocketException ){ +void TcpSocket::setSoLinger( int dolinger ) throw( SocketException ){ linger value; value.l_onoff = dolinger != 0; @@ -269,15 +269,15 @@ int TcpSocket::getReceiveBufferSize() const throw( SocketException ){ int value; - socklen_t length = sizeof( int ); + socklen_t length = sizeof( value ); ::getsockopt( socketHandle, SOL_SOCKET, SO_RCVBUF, (char*)&value, &length ); return value; } //////////////////////////////////////////////////////////////////////////////// -void TcpSocket::setReceiveBufferSize( const int size ) throw( SocketException ){ +void TcpSocket::setReceiveBufferSize( int size ) throw( SocketException ){ - ::setsockopt( socketHandle, SOL_SOCKET, SO_RCVBUF, (char*)&size, sizeof(int) ); + ::setsockopt( socketHandle, SOL_SOCKET, SO_RCVBUF, (char*)&size, sizeof(size) ); } //////////////////////////////////////////////////////////////////////////////// @@ -290,7 +290,7 @@ } //////////////////////////////////////////////////////////////////////////////// -void TcpSocket::setReuseAddress( const bool reuse ) throw( SocketException ){ +void TcpSocket::setReuseAddress( bool reuse ) throw( SocketException ){ int value = reuse? 1 : 0; ::setsockopt( socketHandle, SOL_SOCKET, SO_REUSEADDR, (char*)&value, sizeof(int) ); @@ -300,15 +300,15 @@ int TcpSocket::getSendBufferSize() const throw( SocketException ){ int value; - socklen_t length = sizeof( int ); + socklen_t length = sizeof( value ); ::getsockopt( socketHandle, SOL_SOCKET, SO_SNDBUF, (char*)&value, &length ); return value; } //////////////////////////////////////////////////////////////////////////////// -void TcpSocket::setSendBufferSize( const int size ) throw( SocketException ){ +void TcpSocket::setSendBufferSize( int size ) throw( SocketException ){ - ::setsockopt( socketHandle, SOL_SOCKET, SO_SNDBUF, ( char* )&size, sizeof( int ) ); + ::setsockopt( socketHandle, SOL_SOCKET, SO_SNDBUF, ( char* )&size, sizeof( size ) ); } //////////////////////////////////////////////////////////////////////////////// Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/TcpSocket.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/TcpSocket.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/TcpSocket.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/TcpSocket.h Fri Jan 26 13:11:34 2007 @@ -89,7 +89,7 @@ * @param port The port of the server to connect to. * @throws IOException Thrown if a failure occurred in the connect. */ - virtual void connect( const char* host, const int port ) throw( SocketException ); + virtual void connect( const char* host, int port ) throw( SocketException ); /** * Indicates whether or not this socket is connected to a destination. @@ -123,7 +123,7 @@ * @param linger The linger time in seconds. If 0, linger is off. * @throws SocketException if the operation fails. */ - virtual void setSoLinger( const int linger ) throw( SocketException ); + virtual void setSoLinger( int linger ) throw( SocketException ); /** * Gets the keep alive flag. @@ -137,7 +137,7 @@ * @param keepAlive If true, enables the flag. * @throws SocketException if the operation fails. */ - virtual void setKeepAlive( const bool keepAlive ) throw( SocketException ); + virtual void setKeepAlive( bool keepAlive ) throw( SocketException ); /** * Gets the receive buffer size. @@ -151,7 +151,7 @@ * @param size Number of bytes to set the receive buffer to. * @throws SocketException if the operation fails. */ - virtual void setReceiveBufferSize( const int size ) throw( SocketException ); + virtual void setReceiveBufferSize( int size ) throw( SocketException ); /** * Gets the reuse address flag. @@ -165,7 +165,7 @@ * @param reuse If true, sets the flag. * @throws SocketException if the operation fails. */ - virtual void setReuseAddress( const bool reuse ) throw( SocketException ); + virtual void setReuseAddress( bool reuse ) throw( SocketException ); /** * Gets the send buffer size. @@ -179,7 +179,7 @@ * @param size The number of bytes to set the send buffer to. * @throws SocketException if the operation fails. */ - virtual void setSendBufferSize( const int size ) throw( SocketException ); + virtual void setSendBufferSize( int size ) throw( SocketException ); /** * Gets the timeout for socket operations. @@ -193,7 +193,7 @@ * @param timeout The timeout in milliseconds for socket operations.

* @throws SocketException Thrown if unable to set the information. */ - virtual void setSoTimeout( const int timeout ) throw(SocketException); + virtual void setSoTimeout( int timeout ) throw(SocketException); /** * Closes this object and deallocates the appropriate resources. Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/CommandReader.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/CommandReader.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/CommandReader.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/CommandReader.h Fri Jan 26 13:11:34 2007 @@ -33,14 +33,14 @@ { public: - virtual ~CommandReader(void){} + virtual ~CommandReader(){} /** * Reads a command from the given input stream. * @return The next command available on the stream. * @throws CommandIOException if a problem occurs during the read. */ - virtual Command* readCommand( void ) + virtual Command* readCommand() throw ( CommandIOException ) = 0; }; Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/CommandWriter.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/CommandWriter.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/CommandWriter.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/CommandWriter.h Fri Jan 26 13:11:34 2007 @@ -34,7 +34,7 @@ { public: - virtual ~CommandWriter(void) {} + virtual ~CommandWriter() {} /** * Writes a command to the given output stream. Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/Map.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/Map.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/Map.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/Map.h Fri Jan 26 13:11:34 2007 @@ -102,7 +102,7 @@ /** * @return The number of elements (key/value pairs) in this map. */ - virtual unsigned int size() const; + virtual std::size_t size() const; /** * Gets the value for the specified key. @@ -264,7 +264,7 @@ //////////////////////////////////////////////////////////////////////////// template - unsigned int Map::size() const{ + std::size_t Map::size() const{ return valueMap.size(); } Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/PrimitiveMap.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/PrimitiveMap.cpp?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/PrimitiveMap.cpp (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/PrimitiveMap.cpp Fri Jan 26 13:11:34 2007 @@ -61,7 +61,7 @@ } //////////////////////////////////////////////////////////////////////////////// -unsigned int PrimitiveMap::size() const{ +std::size_t PrimitiveMap::size() const{ return valueNodeMap.size(); } Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/PrimitiveMap.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/PrimitiveMap.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/PrimitiveMap.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/PrimitiveMap.h Fri Jan 26 13:11:34 2007 @@ -378,7 +378,7 @@ /** * @return The number of elements (key/value pairs) in this map. */ - virtual unsigned int size() const; + virtual std::size_t size() const; /** * @returns if there are any entries in the map. Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/Set.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/Set.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/Set.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/Set.h Fri Jan 26 13:11:34 2007 @@ -84,7 +84,7 @@ /** * @return The number of elements in this set. */ - virtual unsigned int size() const; + virtual std::size_t size() const; /** * Adds the given value to the set. @@ -196,7 +196,7 @@ //////////////////////////////////////////////////////////////////////////// template - unsigned int Set::size() const{ + std::size_t Set::size() const{ return values.size(); } Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/BytesMessage.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/BytesMessage.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/BytesMessage.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/BytesMessage.h Fri Jan 26 13:11:34 2007 @@ -35,7 +35,7 @@ * @throws CMSException */ virtual void setBodyBytes( - const unsigned char* buffer, const unsigned long long numBytes ) + const unsigned char* buffer, std::size_t numBytes ) throw( CMSException ) = 0; /** @@ -51,7 +51,7 @@ * Returns the number of bytes contained in the body of this message. * @return number of bytes. */ - virtual unsigned long long getBodyLength() const = 0; + virtual std::size_t getBodyLength() const = 0; /** * Puts the message body in read-only mode and repositions the stream @@ -109,7 +109,7 @@ * been reached * @throws CMSException if an error occurs. */ - virtual int readBytes( std::vector& value ) + virtual std::size_t readBytes( std::vector& value ) throw ( cms::CMSException ) = 0; /** @@ -146,7 +146,7 @@ * been reached * @throws CMSException */ - virtual int readBytes( unsigned char*& buffer, int length ) + virtual std::size_t readBytes( unsigned char*& buffer, std::size_t length ) throw ( cms::CMSException ) = 0; /** @@ -158,8 +158,8 @@ * @throws CMSException */ virtual void writeBytes( const unsigned char* value, - int offset, - int length ) throw ( cms::CMSException ) = 0; + std::size_t offset, + std::size_t length ) throw ( cms::CMSException ) = 0; /** * Reads a Char from the Bytes message stream Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Closeable.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Closeable.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Closeable.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Closeable.h Fri Jan 26 13:11:34 2007 @@ -29,7 +29,7 @@ public: - virtual ~Closeable(void){} + virtual ~Closeable(){} /** * Closes this object and deallocates the appropriate resources. Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Connection.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Connection.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Connection.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Connection.h Fri Jan 26 13:11:34 2007 @@ -34,7 +34,7 @@ { public: - virtual ~Connection(void) {} + virtual ~Connection() {} /** * Closes this connection as well as any Sessions Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/ConnectionFactory.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/ConnectionFactory.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/ConnectionFactory.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/ConnectionFactory.h Fri Jan 26 13:11:34 2007 @@ -32,7 +32,7 @@ { public: - virtual ~ConnectionFactory(void) {} + virtual ~ConnectionFactory() {} /** * Creates a connection with the default user identity. The @@ -42,7 +42,7 @@ * @return Pointer to a connection object, caller owns the pointer * @throws CMSException */ - virtual Connection* createConnection(void) throw ( CMSException ) = 0; + virtual Connection* createConnection() throw ( CMSException ) = 0; /** * Creates a connection with the specified user identity. The Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Destination.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Destination.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Destination.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Destination.h Fri Jan 26 13:11:34 2007 @@ -43,19 +43,19 @@ /** * Destructor */ - virtual ~Destination(void){} + virtual ~Destination(){} /** * Retrieve the Destination Type for this Destination * @return The Destination Type */ - virtual DestinationType getDestinationType(void) const = 0; + virtual DestinationType getDestinationType() const = 0; /** * Converts the Destination Name into a String * @return string name */ - virtual std::string toString(void) const = 0; + virtual std::string toString() const = 0; /** * Converts the Destination to a String value representing the @@ -63,14 +63,14 @@ * necessarily equal to the User Supplied name of the Destination * @return Provider specific Name */ - virtual std::string toProviderString(void) const = 0; + virtual std::string toProviderString() const = 0; /** * Creates a new instance of this destination type that is a * copy of this one, and returns it. * @returns cloned copy of this object */ - virtual cms::Destination* clone(void) const = 0; + virtual cms::Destination* clone() const = 0; /** * Copies the contents of the given Destinastion object to this one. @@ -84,7 +84,7 @@ * but necessary due to C++ restrictions. * @return const reference to a properties object. */ - virtual const activemq::util::Properties& getProperties(void) const = 0; + virtual const activemq::util::Properties& getProperties() const = 0; }; } Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/ExceptionListener.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/ExceptionListener.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/ExceptionListener.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/ExceptionListener.h Fri Jan 26 13:11:34 2007 @@ -26,7 +26,7 @@ { public: - virtual ~ExceptionListener(void) {} + virtual ~ExceptionListener() {} /** * Called when an exception occurs. Once notified of an exception Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/MapMessage.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/MapMessage.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/MapMessage.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/MapMessage.h Fri Jan 26 13:11:34 2007 @@ -40,7 +40,7 @@ { public: - virtual ~MapMessage(void) {} + virtual ~MapMessage() {} /** * Returns an Enumeration of all the names in the MapMessage @@ -49,7 +49,7 @@ * name of an item in the MapMessage * @throws CMSException */ - virtual std::vector< std::string > getMapNames(void) const = 0; + virtual std::vector< std::string > getMapNames() const = 0; /** * Indicates whether an item exists in this MapMessage object. Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/MessageConsumer.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/MessageConsumer.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/MessageConsumer.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/MessageConsumer.h Fri Jan 26 13:11:34 2007 @@ -29,14 +29,14 @@ { public: - virtual ~MessageConsumer(void) {} + virtual ~MessageConsumer() {} /** * Synchronously Receive a Message * @return new message * @throws CMSException */ - virtual Message* receive(void) throw ( CMSException ) = 0; + virtual Message* receive() throw ( CMSException ) = 0; /** * Synchronously Receive a Message, time out after defined interval. @@ -52,7 +52,7 @@ * @return new message * @throws CMSException */ - virtual Message* receiveNoWait(void) throw ( CMSException ) = 0; + virtual Message* receiveNoWait() throw ( CMSException ) = 0; /** * Sets the MessageListener that this class will send notifs on @@ -64,14 +64,14 @@ * Gets the MessageListener that this class will send notifs on * @param MessageListener interface pointer */ - virtual MessageListener* getMessageListener(void) const = 0; + virtual MessageListener* getMessageListener() const = 0; /** * Gets this message consumer's message selector expression. * @return This Consumer's selector expression or "". * @throws cms::CMSException */ - virtual std::string getMessageSelector(void) const + virtual std::string getMessageSelector() const throw ( cms::CMSException ) = 0; }; Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/MessageListener.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/MessageListener.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/MessageListener.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/MessageListener.h Fri Jan 26 13:11:34 2007 @@ -17,8 +17,6 @@ #ifndef _CMS_MESSAGELISTENER_H_ #define _CMS_MESSAGELISTENER_H_ - -//#include namespace cms{ @@ -27,7 +25,7 @@ class MessageListener{ public: - virtual ~MessageListener(void){} + virtual ~MessageListener(){} /** * Called asynchronously when a new message is received, the message Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Queue.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Queue.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Queue.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Queue.h Fri Jan 26 13:11:34 2007 @@ -30,7 +30,7 @@ public: - virtual ~Queue(void){} + virtual ~Queue(){} /** * Gets the name of this queue. Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Session.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Session.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Session.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Session.h Fri Jan 26 13:11:34 2007 @@ -74,7 +74,7 @@ public: - virtual ~Session(void) {} + virtual ~Session() {} /** * Closes this session as well as any active child consumers or @@ -88,14 +88,14 @@ * locks currently held. * @throws CMSException */ - virtual void commit(void) throw ( CMSException ) = 0; + virtual void commit() throw ( CMSException ) = 0; /** * Rollsback all messages done in this transaction and releases any * locks currently held. * @throws CMSException */ - virtual void rollback(void) throw ( CMSException ) = 0; + virtual void rollback() throw ( CMSException ) = 0; /** * Creates a MessageConsumer for the specified destination. @@ -190,28 +190,28 @@ * @return new TemporaryQueue pointer that is owned by the caller. * @throws CMSException */ - virtual TemporaryQueue* createTemporaryQueue(void) + virtual TemporaryQueue* createTemporaryQueue() throw ( CMSException ) = 0; /** * Creates a TemporaryTopic object. * @throws CMSException */ - virtual TemporaryTopic* createTemporaryTopic(void) + virtual TemporaryTopic* createTemporaryTopic() throw ( CMSException ) = 0; /** * Creates a new Message * @throws CMSException */ - virtual Message* createMessage(void) + virtual Message* createMessage() throw ( CMSException ) = 0; /** * Creates a BytesMessage * @throws CMSException */ - virtual BytesMessage* createBytesMessage(void) + virtual BytesMessage* createBytesMessage() throw ( CMSException) = 0; /** @@ -222,14 +222,14 @@ */ virtual BytesMessage* createBytesMessage( const unsigned char* bytes, - unsigned long long bytesSize ) + std::size_t bytesSize ) throw ( CMSException) = 0; /** * Creates a new TextMessage * @throws CMSException */ - virtual TextMessage* createTextMessage(void) + virtual TextMessage* createTextMessage() throw ( CMSException ) = 0; /** @@ -244,20 +244,20 @@ * Creates a new MapMessage * @throws CMSException */ - virtual MapMessage* createMapMessage(void) + virtual MapMessage* createMapMessage() throw ( CMSException ) = 0; /** * Returns the acknowledgement mode of the session. * @return the Sessions Acknowledge Mode */ - virtual AcknowledgeMode getAcknowledgeMode(void) const = 0; + virtual AcknowledgeMode getAcknowledgeMode() const = 0; /** * Gets if the Sessions is a Transacted Session * @return transacted true - false. */ - virtual bool isTransacted(void) const = 0; + virtual bool isTransacted() const = 0; }; Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/TemporaryQueue.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/TemporaryQueue.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/TemporaryQueue.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/TemporaryQueue.h Fri Jan 26 13:11:34 2007 @@ -30,13 +30,13 @@ { public: - virtual ~TemporaryQueue(void) {} + virtual ~TemporaryQueue() {} /** * Gets the name of this queue. * @return The queue name. */ - virtual std::string getQueueName(void) const + virtual std::string getQueueName() const throw( CMSException ) = 0; }; Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/TemporaryTopic.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/TemporaryTopic.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/TemporaryTopic.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/TemporaryTopic.h Fri Jan 26 13:11:34 2007 @@ -30,13 +30,13 @@ { public: - virtual ~TemporaryTopic(void) {} + virtual ~TemporaryTopic() {} /** * Gets the name of this topic. * @return The topic name. */ - virtual std::string getTopicName(void) + virtual std::string getTopicName() const throw( CMSException ) = 0; }; Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Topic.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Topic.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Topic.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/Topic.h Fri Jan 26 13:11:34 2007 @@ -30,13 +30,13 @@ public: - virtual ~Topic(void) {} + virtual ~Topic() {} /** * Gets the name of this topic. * @return The topic name. */ - virtual std::string getTopicName(void) + virtual std::string getTopicName() const throw( CMSException ) = 0; }; Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/concurrent/MutexTest.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/concurrent/MutexTest.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/concurrent/MutexTest.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/concurrent/MutexTest.h Fri Jan 26 13:11:34 2007 @@ -376,7 +376,7 @@ test.join(); time_t endTime = time( NULL ); - long delta = endTime - startTime; + time_t delta = endTime - startTime; CPPUNIT_ASSERT( delta >= 1 && delta <= 3 ); } Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/concurrent/ThreadTest.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/concurrent/ThreadTest.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/concurrent/ThreadTest.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/concurrent/ThreadTest.h Fri Jan 26 13:11:34 2007 @@ -136,7 +136,7 @@ test.join(); time_t endTime = time( NULL ); - long delta = endTime - startTime; + time_t delta = endTime - startTime; // Should be about 5 seconds that elapsed. CPPUNIT_ASSERT( delta >= 1 && delta <= 3 ); Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/io/BufferedInputStreamTest.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/io/BufferedInputStreamTest.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/io/BufferedInputStreamTest.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/io/BufferedInputStreamTest.h Fri Jan 26 13:11:34 2007 @@ -40,7 +40,7 @@ class MyInputStream : public InputStream{ private: std::string data; - unsigned int pos; + std::size_t pos; public: MyInputStream( const std::string& data ){ @@ -49,9 +49,9 @@ } virtual ~MyInputStream(){} - virtual int available() const throw (IOException){ - int len = data.length(); - return len - (int)pos; + virtual std::size_t available() const throw (IOException){ + std::size_t len = data.length(); + return len - pos; } virtual unsigned char read() throw (IOException){ if( pos >= data.length() ){ @@ -60,11 +60,11 @@ return data.c_str()[pos++]; } - virtual int read( unsigned char* buffer, int bufferSize ) throw (IOException){ - unsigned int numToRead = std::min( bufferSize, available() ); + virtual std::size_t read( unsigned char* buffer, std::size_t bufferSize ) throw (IOException){ + std::size_t numToRead = std::min( bufferSize, available() ); const char* str = data.c_str(); - for( unsigned int ix=0; ix 100 ){ throw IOException(); Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/network/SocketTest.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/network/SocketTest.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/network/SocketTest.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/network/SocketTest.h Fri Jan 26 13:11:34 2007 @@ -282,7 +282,7 @@ unsigned char buf[500]; memset( buf, 0, 500 ); io::InputStream* istream = client.getInputStream(); - int numRead = istream->read( buf, 500 ); + std::size_t numRead = istream->read( buf, 500 ); CPPUNIT_ASSERT( numRead == 5 ); CPPUNIT_ASSERT( strcmp( (char*)buf, "hello" ) == 0 ); Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/transport/IOTransportTest.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/transport/IOTransportTest.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/transport/IOTransportTest.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/transport/IOTransportTest.h Fri Jan 26 13:11:34 2007 @@ -129,8 +129,8 @@ } } - virtual int read(unsigned char* buffer AMQCPP_UNUSED, - int count AMQCPP_UNUSED) + virtual std::size_t read(unsigned char* buffer AMQCPP_UNUSED, + std::size_t count AMQCPP_UNUSED) throw( io::IOException ) { return 0; } @@ -177,7 +177,7 @@ } virtual void write( const unsigned char* buffer AMQCPP_UNUSED, - int count AMQCPP_UNUSED) + std::size_t count AMQCPP_UNUSED) throw(io::IOException) {} virtual void writeByte(unsigned char v AMQCPP_UNUSED) throw(io::IOException) {} @@ -301,7 +301,7 @@ transport.oneway( &cmd ); const unsigned char* bytes = os.getByteArray(); - int size = os.getByteArraySize(); + std::size_t size = os.getByteArraySize(); CPPUNIT_ASSERT( size >= 5 ); CPPUNIT_ASSERT( bytes[0] == '1' ); CPPUNIT_ASSERT( bytes[1] == '2' ); Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/util/LongTest.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/util/LongTest.h?view=diff&rev=500349&r1=500348&r2=500349 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/util/LongTest.h (original) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/util/LongTest.h Fri Jan 26 13:11:34 2007 @@ -39,9 +39,9 @@ virtual void test(void) { - long x = Long::parseLong("12"); - long y = Long::parseLong("12.1"); - long z = Long::parseLong("42 24"); + long long x = Long::parseLong("12"); + long long y = Long::parseLong("12.1"); + long long z = Long::parseLong("42 24"); CPPUNIT_ASSERT( x == 12 ); CPPUNIT_ASSERT( y == 12 );