From 4955786cd2af7aef46bb44ed733959da1711ef5d Mon Sep 17 00:00:00 2001 From: Andreas Bille Date: Tue, 19 Jun 2001 12:41:05 +0000 Subject: #88432# Added exception specifications for determination of misconfigured index. Now also reading from lowercase filenames --- xmlhelp/source/cxxhelp/db/BlockManager.cxx | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'xmlhelp/source/cxxhelp/db/BlockManager.cxx') diff --git a/xmlhelp/source/cxxhelp/db/BlockManager.cxx b/xmlhelp/source/cxxhelp/db/BlockManager.cxx index a833fa0573b1..3d3f91560c30 100644 --- a/xmlhelp/source/cxxhelp/db/BlockManager.cxx +++ b/xmlhelp/source/cxxhelp/db/BlockManager.cxx @@ -2,9 +2,9 @@ * * $RCSfile: BlockManager.cxx,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: abi $ $Date: 2001-06-06 14:48:47 $ + * last change: $Author: abi $ $Date: 2001-06-19 13:41:04 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -68,18 +68,25 @@ using namespace ::xmlsearch; +using namespace ::xmlsearch::excep; using namespace ::xmlsearch::db; -BlockManager::BlockManager( DBEnv* dbenv ) +BlockManager::BlockManager( DBEnv* dbenv ) throw( IOException ) : oldest_( 0 ), newest_( 0 ), dbenv_( dbenv ), blockused_( 0 ), blockTable_( dbenv_ ? dbenv_->getBlockCount() : 0 ) // Hardcoded headerlen? { - mapStorage2Memory( 0 ); + if( blockTable_.size() ) + mapStorage2Memory( 0 ); + else + { + delete dbenv_; + throw IOException( rtl::OUString::createFromAscii( "BlockManager::BlockManager -> no blockcount" ) ); + } } -- cgit