cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF subversion and git services (JIRA)" <>
Subject [jira] [Commented] (CB-5631) progress returns excatly twice as much loaded bytes on android
Date Mon, 10 Feb 2014 23:23:32 GMT


ASF subversion and git services commented on CB-5631:

Commit 8374b3dd67ecdb62423ff55ccb9d0a4454cfe4a4 in branch refs/heads/master from [~cdmahoney]
[;h=8374b3d ]

CB-5631 Removed[] buffer)[] buffer) calls[] bytes, int
offset, int count).  As SimpleTrackingInputStream overrides both these
methods a call to[] buffer) results
in a call to[] bytes, int offset,
int count) - and two calls to SimpleTrackingInputStream.updateBytesRead,
so the counter bytesRead gets incremented twice for each read.

> progress returns excatly twice as much loaded bytes on android
> ------------------------------------------------------------------------------------
>                 Key: CB-5631
>                 URL:
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: Android, Plugin File Transfer
>    Affects Versions: 3.2.0
>            Reporter: Malte Legenhausen
>            Assignee: Andrew Grieve
> When I download a file under android and calculate the progress of the download the onprogress
event.loaded variable is set to twice as much bytes as there where total available.
> I fixed the bug for me by simply dividing the result of getTotalRawBytesRead by 2.
> This bug occurs since cordova 3.0.0 only on Android. Tests on iOS return the right result.
I downloaded a video file from an apache http server.

This message was sent by Atlassian JIRA

View raw message