You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by ta...@apache.org on 2009/11/17 19:56:42 UTC

svn commit: r881440 - in /activemq/activemq-cpp/trunk/activemq-cpp/src/main: activemq/commands/ActiveMQStreamMessage.cpp decaf/internal/util/HexStringParser.h

Author: tabish
Date: Tue Nov 17 18:56:42 2009
New Revision: 881440

URL: http://svn.apache.org/viewvc?rev=881440&view=rev
Log:
Fix a couple of warnings on Windows

Modified:
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/commands/ActiveMQStreamMessage.cpp
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/HexStringParser.h

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/commands/ActiveMQStreamMessage.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/commands/ActiveMQStreamMessage.cpp?rev=881440&r1=881439&r2=881440&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/commands/ActiveMQStreamMessage.cpp (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/commands/ActiveMQStreamMessage.cpp Tue Nov 17 18:56:42 2009
@@ -278,7 +278,7 @@
     initializeWriting();
     try{
         this->dataOut->write( PrimitiveValueNode::BYTE_ARRAY_TYPE );
-        this->dataOut->writeInt( value.size() );
+        this->dataOut->writeInt( (int)value.size() );
         this->dataOut->write( &value[0], 0, value.size() );
     }
     AMQ_CATCH_ALL_THROW_CMSEXCEPTION()
@@ -300,7 +300,7 @@
 
         if( this->remainingBytes == -1 ) {
 
-            this->dataIn->mark( length + 1 );
+            this->dataIn->mark( (int)length + 1 );
             int type = this->dataIn->read();
 
             if( type == -1 ) {
@@ -320,7 +320,7 @@
 
         if( length <= (size_t)this->remainingBytes ) {
             // small buffer
-            this->remainingBytes -= length;
+            this->remainingBytes -= (int)length;
             this->dataIn->readFully( buffer, 0, length );
             return length;
         } else {
@@ -348,7 +348,7 @@
     initializeWriting();
     try{
         this->dataOut->write( PrimitiveValueNode::BYTE_ARRAY_TYPE );
-        this->dataOut->writeInt( length );
+        this->dataOut->writeInt( (int)length );
         this->dataOut->write( value, offset, length );
     }
     AMQ_CATCH_ALL_THROW_CMSEXCEPTION()

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/HexStringParser.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/HexStringParser.h?rev=881440&r1=881439&r2=881440&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/HexStringParser.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/HexStringParser.h Tue Nov 17 18:56:42 2009
@@ -47,13 +47,13 @@
 
         int EXPONENT_WIDTH;
         int MANTISSA_WIDTH;
-        long EXPONENT_BASE;
-        long MAX_EXPONENT;
-        long MIN_EXPONENT;
-        long MANTISSA_MASK;
-        long sign;
-        long exponent;
-        long mantissa;
+        long long EXPONENT_BASE;
+        long long MAX_EXPONENT;
+        long long MIN_EXPONENT;
+        long long MANTISSA_MASK;
+        long long sign;
+        long long exponent;
+        long long mantissa;
         std::string abandonedNumber;
 
     public: