Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix error when using custom CMapReaderFactory #8567

Merged
merged 1 commit into from Jun 23, 2017

Conversation

ghetolay
Copy link
Contributor

When using a source object on getDocument() with a custom CMapReaderFactory we end up sending that factory to the worker as part of the message. This causes postMessage() to throw because it can't clone a function.

So the param object passed to _fetchDocument() shouldn't have that factory as part of his properties.

It's really trivial so I didn't add test but I could build something if you want.

@ghetolay ghetolay force-pushed the fix_CMapReaderFactory+worker branch from 0d40d85 to 7f79e12 Compare June 23, 2017 14:00
@yurydelendik
Copy link
Contributor

/botio test

@pdfjsbot
Copy link

From: Bot.io (Windows)


Received

Command cmd_test from @yurydelendik received. Current queue size: 0

Live output at: http://54.215.176.217:8877/b86f747666898f4/output.txt

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Received

Command cmd_test from @yurydelendik received. Current queue size: 0

Live output at: http://54.67.70.0:8877/db07b0482b9bf31/output.txt

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Success

Full output at http://54.67.70.0:8877/db07b0482b9bf31/output.txt

Total script time: 16.36 mins

  • Font tests: Passed
  • Unit tests: Passed
  • Regression tests: Passed

@pdfjsbot
Copy link

From: Bot.io (Windows)


Success

Full output at http://54.215.176.217:8877/b86f747666898f4/output.txt

Total script time: 29.97 mins

  • Font tests: Passed
  • Unit tests: Passed
  • Regression tests: Passed

@yurydelendik yurydelendik merged commit d1567a9 into mozilla:master Jun 23, 2017
@yurydelendik
Copy link
Contributor

Thank you for the patch.

@ghetolay ghetolay deleted the fix_CMapReaderFactory+worker branch June 24, 2017 10:31
movsb pushed a commit to movsb/pdf.js that referenced this pull request Jul 14, 2018
…orker

Fix error when using custom CMapReaderFactory
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants