activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r546104 - /activemq/activemq-cpp/trunk/src/decaf/src/main/decaf/io/ByteArrayInputStream.cpp
Date Mon, 11 Jun 2007 11:42:06 GMT
Author: tabish
Date: Mon Jun 11 04:42:05 2007
New Revision: 546104

URL: http://svn.apache.org/viewvc?view=rev&rev=546104
Log:
http://issues.apache.org/activemq/browse/AMQCPP-103

Building Decaf lib

Modified:
    activemq/activemq-cpp/trunk/src/decaf/src/main/decaf/io/ByteArrayInputStream.cpp

Modified: activemq/activemq-cpp/trunk/src/decaf/src/main/decaf/io/ByteArrayInputStream.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/decaf/src/main/decaf/io/ByteArrayInputStream.cpp?view=diff&rev=546104&r1=546103&r2=546104
==============================================================================
--- activemq/activemq-cpp/trunk/src/decaf/src/main/decaf/io/ByteArrayInputStream.cpp (original)
+++ activemq/activemq-cpp/trunk/src/decaf/src/main/decaf/io/ByteArrayInputStream.cpp Mon Jun
11 04:42:05 2007
@@ -60,10 +60,11 @@
     activeBuffer = &defaultBuffer;
 
     // Remove old data
-    defaultBuffer.resize( lbufferSize );
+    defaultBuffer.clear();
+    defaultBuffer.reserve( lbufferSize );
 
-    // Copy to internal buffer
-    std::copy( lbuffer, lbuffer + lbufferSize, &defaultBuffer[0] );
+    // Copy data to internal buffer.
+    defaultBuffer.insert( defaultBuffer.end(), lbuffer, lbuffer + lbufferSize );
 
     // Begin at the Beginning.
     reset();



Mime
View raw message