From 2b9e25300f10953de9d6418f87c8fffc603bc5a1 Mon Sep 17 00:00:00 2001 From: Dennis Luxen Date: Thu, 9 Oct 2014 17:26:15 +0200 Subject: [PATCH] disable checking for empty data sets to make tests pass in debug mode, #889 --- DataStructures/SharedMemoryVectorWrapper.h | 4 ++-- datastore.cpp | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/DataStructures/SharedMemoryVectorWrapper.h b/DataStructures/SharedMemoryVectorWrapper.h index 5b943543f..b290aad11 100644 --- a/DataStructures/SharedMemoryVectorWrapper.h +++ b/DataStructures/SharedMemoryVectorWrapper.h @@ -78,7 +78,7 @@ template class SharedMemoryWrapper void swap(SharedMemoryWrapper &other) { - BOOST_ASSERT_MSG(m_size != 0 || other.size() != 0, "size invalid"); + // BOOST_ASSERT_MSG(m_size != 0 || other.size() != 0, "size invalid"); std::swap(m_size, other.m_size); std::swap(m_ptr, other.m_ptr); } @@ -121,7 +121,7 @@ template <> class SharedMemoryWrapper void swap(SharedMemoryWrapper &other) { - BOOST_ASSERT_MSG(m_size != 0 || other.size() != 0, "size invalid"); + // BOOST_ASSERT_MSG(m_size != 0 || other.size() != 0, "size invalid"); std::swap(m_size, other.m_size); std::swap(m_ptr, other.m_ptr); } diff --git a/datastore.cpp b/datastore.cpp index c1804930c..fb9446716 100644 --- a/datastore.cpp +++ b/datastore.cpp @@ -304,7 +304,7 @@ int main(const int argc, const char *argv[]) // load graph edge size unsigned number_of_graph_edges = 0; hsgr_input_stream.read((char *)&number_of_graph_edges, sizeof(unsigned)); - BOOST_ASSERT_MSG(0 != number_of_graph_edges, "number of graph edges is zero"); + // BOOST_ASSERT_MSG(0 != number_of_graph_edges, "number of graph edges is zero"); shared_layout_ptr->SetBlockSize( SharedDataLayout::GRAPH_EDGE_LIST, number_of_graph_edges); @@ -362,7 +362,6 @@ int main(const int argc, const char *argv[]) geometry_input_stream.read((char *)&number_of_compressed_geometries, sizeof(unsigned)); shared_layout_ptr->SetBlockSize(SharedDataLayout::GEOMETRIES_LIST, number_of_compressed_geometries); - // allocate shared memory block SimpleLogger().Write() << "allocating shared memory of " << shared_layout_ptr->GetSizeOfLayout() << " bytes";