diff --git a/src/core/bidi.js b/src/core/bidi.js index 16219ce09..a89e713b5 100644 --- a/src/core/bidi.js +++ b/src/core/bidi.js @@ -119,8 +119,8 @@ var bidi = PDFJS.bidi = (function bidiClosure() { } // Get types and fill arrays - chars.length = 0; - types.length = 0; + chars.length = strLength; + types.length = strLength; var numBidi = 0; var i, ii;