activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r711372 - /activemq/activemq-cpp/trunk/src/main/decaf/io/BufferedInputStream.h
Date Tue, 04 Nov 2008 20:08:31 GMT
Author: tabish
Date: Tue Nov  4 12:08:30 2008
New Revision: 711372

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

Move deletion of buffer to the destructor, not the close method.

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

Modified: activemq/activemq-cpp/trunk/src/main/decaf/io/BufferedInputStream.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/main/decaf/io/BufferedInputStream.h?rev=711372&r1=711371&r2=711372&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/src/main/decaf/io/BufferedInputStream.h (original)
+++ activemq/activemq-cpp/trunk/src/main/decaf/io/BufferedInputStream.h Tue Nov  4 12:08:30
2008
@@ -94,7 +94,7 @@
          * input stream.
          */
         virtual std::size_t available() const throw ( IOException ) {
-            if( buffer == NULL ) {
+            if( buffer == NULL || this->isClosed() ) {
                 throw IOException(
                     __FILE__, __LINE__,
                     "BufferedInputStream::available - Buffer was closed");



Mime
View raw message