mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-29 20:07:30 +09:00
[Basilisk] [pdf.js] Don't follow redirects on range requests for PDFs.
This commit is contained in:
parent
b83d024efb
commit
f5cf8f0558
1 changed files with 1 additions and 0 deletions
|
|
@ -95,6 +95,7 @@ var NetworkManager = (function NetworkManagerClosure() {
|
||||||
var rangeStr = args.begin + '-' + (args.end - 1);
|
var rangeStr = args.begin + '-' + (args.end - 1);
|
||||||
xhr.setRequestHeader('Range', 'bytes=' + rangeStr);
|
xhr.setRequestHeader('Range', 'bytes=' + rangeStr);
|
||||||
pendingRequest.expectedStatus = 206;
|
pendingRequest.expectedStatus = 206;
|
||||||
|
xhr.channel.QueryInterface(Ci.nsIHttpChannel).redirectionLimit = 0;
|
||||||
} else {
|
} else {
|
||||||
pendingRequest.expectedStatus = 200;
|
pendingRequest.expectedStatus = 200;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue