Skip to content

Commit

Permalink
Applied patch to fix issue 1098
Browse files Browse the repository at this point in the history
git-svn-id: https://tesseract-ocr.googlecode.com/svn/trunk@1066 d0cd1f9f-072b-0410-8dd7-cf729c803f20
  • Loading branch information
theraysmith@gmail.com committed Apr 23, 2014
1 parent bfb0e39 commit a9f483c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ccstruct/fontinfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@ bool read_spacing_info(FILE *f, FontInfo* fi, bool swap) {
if (fread(&fs->x_gap_before, sizeof(fs->x_gap_before), 1, f) != 1 ||
fread(&fs->x_gap_after, sizeof(fs->x_gap_after), 1, f) != 1 ||
fread(&kern_size, sizeof(kern_size), 1, f) != 1) {
delete fs;
return false;
}
if (swap) {
Expand All @@ -199,6 +200,7 @@ bool read_spacing_info(FILE *f, FontInfo* fi, bool swap) {
}
if (kern_size > 0 && (!fs->kerned_unichar_ids.DeSerialize(swap, f) ||
!fs->kerned_x_gaps.DeSerialize(swap, f))) {
delete fs;
return false;
}
fi->add_spacing(i, fs);
Expand Down

0 comments on commit a9f483c

Please sign in to comment.