Fix truncated reports with multi-byte characters

This commit is contained in:
Dan Stillman 2017-01-26 22:32:33 -05:00
parent 31ed9bd70b
commit e6d7ae8e2f

View file

@ -1220,7 +1220,7 @@ AsyncChannel.prototype = {
.createInstance(Components.interfaces.nsIScriptableUnicodeConverter);
converter.charset = "UTF-8";
let inputStream = converter.convertToInputStream(data);
listenerWrapper.onDataAvailable(this, context, inputStream, 0, data.length);
listenerWrapper.onDataAvailable(this, context, inputStream, 0, inputStream.available());
listenerWrapper.onStopRequest(this, context, this.status);
}