Permalink
Browse files

Fix #388, indextool crash on unexistent index

  • Loading branch information...
klirichek committed Jul 20, 2018
1 parent 971a063 commit af2326cd2927effbad7bec88e8dc238a566cf27e
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/indextool.cpp
@@ -1405,11 +1405,11 @@ int main ( int argc, char ** argv )
sphConfigureCommon ( hConf );
// common part for several commands, check and preload index
CSphIndex * pIndex = NULL;
CSphIndex * pIndex = nullptr;
while ( !sIndex.IsEmpty() && eCommand!=CMD_OPTIMIZEKLISTS )
{
// check config
if ( !hConf["index"](sIndex) )
if ( !hConf["index"].Exists(sIndex) )
sphDie ( "index '%s': no such index in config\n", sIndex.cstr() );
// only need config-level settings for --htmlstrip

0 comments on commit af2326c

Please sign in to comment.