BIND 10 trac2850_2, updated. 3c98ade56f07c44740f1bde2e37f8fdc9842bd18 [2850] Looks like flush() finalizes base_sgmt_, so we free before that

BIND 10 source code commits bind10-changes at lists.isc.org
Mon May 13 08:18:17 UTC 2013


The branch, trac2850_2 has been updated
       via  3c98ade56f07c44740f1bde2e37f8fdc9842bd18 (commit)
      from  bf30f052334922f729c8805f109f838ec1a126b9 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 3c98ade56f07c44740f1bde2e37f8fdc9842bd18
Author: Mukund Sivaraman <muks at isc.org>
Date:   Mon May 13 13:47:45 2013 +0530

    [2850] Looks like flush() finalizes base_sgmt_, so we free before that

-----------------------------------------------------------------------

Summary of changes:
 src/lib/util/memory_segment_mapped.cc |    5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

-----------------------------------------------------------------------
diff --git a/src/lib/util/memory_segment_mapped.cc b/src/lib/util/memory_segment_mapped.cc
index 5d11986..2d0992d 100644
--- a/src/lib/util/memory_segment_mapped.cc
+++ b/src/lib/util/memory_segment_mapped.cc
@@ -137,10 +137,6 @@ struct MemorySegmentMapped::Impl {
         reserveMemory();
     }
 
-    ~Impl() {
-        freeReservedMemory();
-    }
-
     void reserveMemory() {
         if (!read_only_) {
             // Reserve a named address for use during setNamedAddress().
@@ -261,6 +257,7 @@ MemorySegmentMapped::MemorySegmentMapped(const std::string& filename,
 
 MemorySegmentMapped::~MemorySegmentMapped() {
     if (impl_->base_sgmt_ && !impl_->read_only_) {
+        impl_->freeReservedMemory();
         impl_->base_sgmt_->flush(); // note: this is exception free
     }
     delete impl_;



More information about the bind10-changes mailing list