DataRequest: More consistent progress report

Trigger DownloadProgress after DataReceived, similar to how other BUrlRequest
classes behave.

Change-Id: I4858c3736b1b1ebec55af9903dbfd4b976a77df3
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3073
Reviewed-by: waddlesplash <[email protected]>
This commit is contained in:
Leorize
2020-07-25 18:13:20 +00:00
committed by waddlesplash
parent 9e404c539f
commit e1de8e8c21
+3 -2
View File
@@ -118,9 +118,10 @@ BDataRequest::_ProtocolLoop()
if (fListener != NULL) {
fListener->HeadersReceived(this, fResult);
fListener->DownloadProgress(this, length, length);
if (length > 0)
if (length > 0) {
fListener->DataReceived(this, payload, 0, length);
fListener->DownloadProgress(this, length, length);
}
}
if (isBase64)