From: Yury Delendik Date: Thu, 5 Apr 2012 16:34:55 +0000 (-0500) Subject: Merge remote-tracking branch 'mozilla/master' into convert-docinfo X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=5dd4c0278dc8b983bd31e2d762454b1d70c6bb04;p=pdf.js.git Merge remote-tracking branch 'mozilla/master' into convert-docinfo Conflicts: src/core.js --- 5dd4c0278dc8b983bd31e2d762454b1d70c6bb04 diff --cc src/core.js index 3f3e952,10ae7d0..15cd147 --- a/src/core.js +++ b/src/core.js @@@ -596,15 -597,8 +597,15 @@@ var PDFDocModel = (function PDFDocModel }, getDocumentInfo: function PDFDocModel_getDocumentInfo() { var info; - if (this.xref.trailer.has('Info')) - info = this.xref.trailer.get('Info'); + if (this.xref.trailer.has('Info')) { - var infoDict = this.xref.fetch(this.xref.trailer.get('Info')); ++ var infoDict = this.xref.trailer.get('Info'); + + info = {}; + infoDict.forEach(function(key, value) { + info[key] = typeof value !== 'string' ? value : + stringToPDFString(value); + }); + } return shadow(this, 'getDocumentInfo', info); },