From 601e5148b50411908b7dc6163f560f7cc62622e1 Mon Sep 17 00:00:00 2001 From: Kurt Jung Date: Tue, 10 Sep 2013 16:45:03 -0400 Subject: Bruno Michel identified and fixed a problem with non-cp1252 encodings, specifically in the way differences with cp1252 are stored and accessed. Thanks, Bruno. --- fpdf.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fpdf.go b/fpdf.go index 51dfad1..850dc1e 100644 --- a/fpdf.go +++ b/fpdf.go @@ -1216,8 +1216,8 @@ func (f *Fpdf) AddFont(familyStr, styleStr, fileStr string) { } } if n < 0 { - n = len(f.diffs) + 1 - f.diffs[n] = info.Diff + f.diffs = append(f.diffs, info.Diff) + n = len(f.diffs) } info.DiffN = n } -- cgit v1.2.1-24-ge1ad