|
|
@ -15,7 +15,7 @@ |
|
|
|
* limitations under the License. |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
/* globals PDFJS, createPromiseCapability, LocalPdfManager, NetworkPdfManager, |
|
|
|
/* globals PDFJS, createPromiseCapability, LocalPdfManager, NetworkPdfManager, |
|
|
|
NetworkManager, isInt, RANGE_CHUNK_SIZE, MissingPDFException, |
|
|
|
NetworkManager, isInt, MissingPDFException, |
|
|
|
UnexpectedResponseException, PasswordException, Promise, warn, |
|
|
|
UnexpectedResponseException, PasswordException, Promise, warn, |
|
|
|
PasswordResponses, InvalidPDFException, UnknownErrorException, |
|
|
|
PasswordResponses, InvalidPDFException, UnknownErrorException, |
|
|
|
XRefParseException, Ref, info, globalScope, error, MessageHandler */ |
|
|
|
XRefParseException, Ref, info, globalScope, error, MessageHandler */ |
|
|
@ -160,7 +160,7 @@ var WorkerMessageHandler = PDFJS.WorkerMessageHandler = { |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
source.length = length; |
|
|
|
source.length = length; |
|
|
|
if (length <= 2 * RANGE_CHUNK_SIZE) { |
|
|
|
if (length <= 2 * source.rangeChunkSize) { |
|
|
|
// The file size is smaller than the size of two chunks, so it does
|
|
|
|
// The file size is smaller than the size of two chunks, so it does
|
|
|
|
// not make any sense to abort the request and retry with a range
|
|
|
|
// not make any sense to abort the request and retry with a range
|
|
|
|
// request.
|
|
|
|
// request.
|
|
|
|