[
https://issues.apache.org/jira/browse/CB-7862?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15417828#comment-15417828
]
Tony Leung commented on CB-7862:
--------------------------------
Now that the chunk size is - FileReader.READ_CHUNK_SIZE = 256*1024;
I found a bug on iOS that readAsDataURL in CDVFile.m, converting it to Base64
will not work because the chunk size 262144 is not dividable by 3.
The quick fix will be FileReader.READ_CHUNK_SIZE = (256*1024) - 1
Should I open a bug for that?
> FileReader reads large files in a single chunk causing OOM exceptions
> ---------------------------------------------------------------------
>
> Key: CB-7862
> URL: https://issues.apache.org/jira/browse/CB-7862
> Project: Apache Cordova
> Issue Type: Bug
> Components: Plugin File
> Affects Versions: 4.0.0
> Environment: Android
> Reporter: shenzhuxi
> Assignee: Jason Ginchereau
> Priority: Critical
>
> In Android, I tried to copy a 14MB file from html file input with
> org.apache.cordova.file 1.3.1. The App crashed and a 0 byte file was copied.
> I use http://ngcordova.com/ and here is my code
> https://github.com/shenzhuxi/readiator/blob/master/src/js/cordova-index.js.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]