Fixed issue 1102

git-svn-id: https://tesseract-ocr.googlecode.com/svn/trunk@1069 d0cd1f9f-072b-0410-8dd7-cf729c803f20
This commit is contained in:
theraysmith@gmail.com 2014-04-24 00:10:59 +00:00
parent 600d9451cb
commit c3166382db

View File

@ -54,9 +54,9 @@ int CubeClassifier::UnicharClassifySample(
pixGetHeight(page_pix) - char_box.top(),
char_box.width(), char_box.height());
CharAltList* alt_list = cube_obj->RecognizeChar();
alt_list->Sort();
CharSet* char_set = cube_cntxt_->CharacterSet();
if (alt_list != NULL) {
alt_list->Sort();
CharSet* char_set = cube_cntxt_->CharacterSet();
for (int i = 0; i < alt_list->AltCount(); ++i) {
// Convert cube representation to a shape_id.
int alt_id = alt_list->Alt(i);