[Pkg-javascript-commits] [pdf.js] 23/139: Minor node/pdf2svg.js fixes.
David Prévot
taffit at moszumanska.debian.org
Fri Jan 9 21:18:22 UTC 2015
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository pdf.js.
commit 6048c8a910d9ad75373a85dc1b1a35dcd2c028d6
Author: Yury Delendik <ydelendik at mozilla.com>
Date: Wed Oct 22 09:59:20 2014 -0500
Minor node/pdf2svg.js fixes.
---
examples/node/domstubs.js | 1 +
examples/node/pdf2svg.js | 3 ++-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/examples/node/domstubs.js b/examples/node/domstubs.js
index b0e422b..7149f00 100644
--- a/examples/node/domstubs.js
+++ b/examples/node/domstubs.js
@@ -16,6 +16,7 @@ var style = {
function xmlEncode(s){
var i = 0, ch;
+ s = String(s);
while (i < s.length && (ch = s[i]) !== '&' && ch !== '<' &&
ch !== '\"' && ch !== '\n' && ch !== '\r' && ch !== '\t') {
i++;
diff --git a/examples/node/pdf2svg.js b/examples/node/pdf2svg.js
index f5979ca..1967ee1 100644
--- a/examples/node/pdf2svg.js
+++ b/examples/node/pdf2svg.js
@@ -14,9 +14,10 @@ global.window = global;
global.navigator = { userAgent: 'node' };
global.PDFJS = {};
+require('./domstubs.js');
+
PDFJS.workerSrc = true;
require('../../build/singlefile/build/pdf.combined.js');
-require('./domstubs.js');
// Loading file from file system into typed array
var pdfPath = process.argv[2] || '../../web/compressed.tracemonkey-pldi-09.pdf';
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/pdf.js.git
More information about the Pkg-javascript-commits
mailing list