activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r730156 - /activemq/activemq-cpp/trunk/src/main/decaf/net/URI.cpp
Date Tue, 30 Dec 2008 15:45:47 GMT
Author: tabish
Date: Tue Dec 30 07:45:46 2008
New Revision: 730156

URL: http://svn.apache.org/viewvc?rev=730156&view=rev
Log:
Fix string usage on 64 bit platforms where string::npos is 8 bytes and not 4.

Modified:
    activemq/activemq-cpp/trunk/src/main/decaf/net/URI.cpp

Modified: activemq/activemq-cpp/trunk/src/main/decaf/net/URI.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/main/decaf/net/URI.cpp?rev=730156&r1=730155&r2=730156&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/src/main/decaf/net/URI.cpp (original)
+++ activemq/activemq-cpp/trunk/src/main/decaf/net/URI.cpp Tue Dec 30 07:45:46 2008
@@ -612,8 +612,8 @@
     }
 
     // count the number of '/'s, to determine number of segments
-    unsigned int index = -1;
-    unsigned int pathlen = path.length();
+    std::size_t index = -1;
+    std::size_t pathlen = path.length();
     unsigned int size = 0;
 
     if( pathlen > 0 && path.at(0) != '/' ) {
@@ -630,8 +630,8 @@
     std::vector<bool> include( size );
 
     // break the path into segments and store in the list
-    unsigned int current = 0;
-    unsigned int index2 = 0;
+    std::size_t current = 0;
+    std::size_t index2 = 0;
 
     index = ( pathlen > 0 && path.at(0) == '/' ) ? 1 : 0;
     while( ( index2 = path.find( '/', index + 1 ) ) != string::npos ) {



Mime
View raw message