From 1be8c5e7ed4d61f52c18580c7e8e0939bf5658ac Mon Sep 17 00:00:00 2001 From: Chris Jones Date: Sat, 18 Jun 2011 21:18:56 -0700 Subject: [PATCH] CharSet is optional --- pdf.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/pdf.js b/pdf.js index 9c4344fab..c0e4791d4 100644 --- a/pdf.js +++ b/pdf.js @@ -1912,9 +1912,11 @@ var CanvasGraphics = (function() { // Get the font charset if any var charset = descriptor.get("CharSet"); - assertWellFormed(IsString(charset), "invalid charset"); + if (charset) { + assertWellFormed(IsString(charset), "invalid charset"); - charset = charset.split("/"); + charset = charset.split("/"); + } } else if (IsName(encoding)) { var encoding = Encodings[encoding.name]; if (!encoding)