Minor corrections to search algorithm for .cfg directory.