Fix memory leak in ladders-remote

This commit is contained in:
Guangcong Luo 2020-06-09 18:30:45 -07:00
parent f4c680ac68
commit b53480b364
2 changed files with 2 additions and 1 deletions

View File

@ -85,9 +85,9 @@ export class NetStream extends Streams.ReadWriteStream {
response.setEncoding('utf-8');
this.nodeReadableStream = response;
this.response = response;
resolveResponse(response);
this.statusCode = response.statusCode || null;
this.headers = response.headers;
resolveResponse(response);
response.on('data', data => {
this.push(data);
});

View File

@ -79,6 +79,7 @@ class LoginServerInstance {
this.openRequests--;
return [json.json!, null];
} catch (error) {
this.openRequests--;
return [null, error];
}
}