From e057f61524e81f2ac37b330d3a906efbd8e169a2 Mon Sep 17 00:00:00 2001 From: Abs62 Date: Thu, 30 Jun 2016 17:40:20 +0300 Subject: [PATCH] Epwing: Handle one more exception while open dictionary --- epwing.cc | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/epwing.cc b/epwing.cc index f2234b0c..81166fa9 100644 --- a/epwing.cc +++ b/epwing.cc @@ -964,8 +964,17 @@ vector< sptr< Dictionary::Class > > makeDictionaries( string mainDirectory = i->substr( 0, ndir ); Epwing::Book::EpwingBook dict; - - int subBooksNumber = dict.setBook( mainDirectory ); + int subBooksNumber = 0; + try + { + subBooksNumber = dict.setBook( mainDirectory ); + } + catch( std::exception & e ) + { + gdWarning( "Epwing dictionary initializing failed: %s, error: %s\n", + mainDirectory.c_str(), e.what() ); + continue; + } for( int sb = 0; sb < subBooksNumber; sb++ ) {