mirror of
https://github.com/yuzu-emu/liftinstall.git
synced 2024-11-22 11:25:41 +01:00
Fix usage of wrong streaming buffer in frontend
This commit is contained in:
parent
b32e9f6f33
commit
d4dd3fb182
@ -77,14 +77,12 @@ function stream_ajax(path, callback, successCallback, failCallback, data) {
|
||||
|
||||
req.onreadystatechange = function() {
|
||||
if(req.readyState > 2) {
|
||||
var newData = req.responseText.substr(req.seenBytes);
|
||||
|
||||
buffer += newData;
|
||||
buffer += req.responseText.substr(req.seenBytes);
|
||||
|
||||
var pointer;
|
||||
while ((pointer = newData.indexOf("\n")) >= 0) {
|
||||
var line = newData.substring(0, pointer).trim();
|
||||
newData = newData.substring(pointer + 1);
|
||||
while ((pointer = buffer.indexOf("\n")) >= 0) {
|
||||
var line = buffer.substring(0, pointer).trim();
|
||||
buffer = buffer.substring(pointer + 1);
|
||||
|
||||
if (line.length === 0) {
|
||||
continue;
|
||||
|
Loading…
Reference in New Issue
Block a user