fix crash
This commit is contained in:
parent
66fdd5ff28
commit
b223edc357
1 changed files with 6 additions and 2 deletions
8
queue.js
8
queue.js
|
@ -74,7 +74,7 @@ class Binary extends Response {
|
||||||
if (!line) { return; }
|
if (!line) { return; }
|
||||||
this._lines.push(line);
|
this._lines.push(line);
|
||||||
|
|
||||||
if (line.startsWith("ACK")) { // no art!
|
if (line.startsWith("ACK") || line.startsWith("OK")) { // no art!
|
||||||
this._done(this._lines);
|
this._done(this._lines);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -84,7 +84,11 @@ class Binary extends Response {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!this._binary) {
|
if (!this._binary) {
|
||||||
let line = this._getLine();
|
let line = "";
|
||||||
|
while (1) {
|
||||||
|
line = this._getLine();
|
||||||
|
if (line.startsWith("binary")) { break; }
|
||||||
|
}
|
||||||
if (!line) { return; }
|
if (!line) { return; }
|
||||||
this._lines.push(line);
|
this._lines.push(line);
|
||||||
this._binary = Number(line.split(": ").pop());
|
this._binary = Number(line.split(": ").pop());
|
||||||
|
|
Loading…
Reference in a new issue