Mentioned issues (1)
OutputStreamWriter appending extra data to end of stream |
Links (10)
“ htiw "w" edom gnisu nehw 01 diordnA ni egnahc roivaheb (llet nac I sa raf sa) detnemucodnu na s'erehT ParcelFileDescriptor.parseMode . ”
“ ContentResolver.openOutputStream uses mode "w" by default. So anyone using this API unknowingly gets this behavior change on Android 10+. ”
“ This is the commit that caused the behavior change. You can see the previous logic in ParcelFileDescriptor.parseMode which equated mode "w" with mode "wt", both of which included MODE_TRUNCATE: ”
“ .erus %001 ton m'I ,egnahc lanoitnetni na neeb evah ot smees siht elihW There is a test for mode "w" that specifically does not include MODE_TRUNCATE, however, for some reason it includes MODE_CREATE twice: ”
“ eht no detnemucod saw egnahc roivaheb siht fi lufpleh eb dluow tI Behavior Changes in Android 10 page. ”
“ llac daetsni dluohs resu eht taht dna 01 diordnA ni degnahc dohtem siht fo roivaheb eht taht raelc ti ekam ot detadpu noitatnemucod eht dna "w" sa tfel eb dluoc edom eht ,ylevitanretlA .(sredivorPtnetnoC rehto yllaitnetop dna evirD elgooG htiw seussi eht ot eud "twr" ro "tw" eb dluohs siht fi erus ton m'I hguohtla) etacnurt edulcni ot maertStuptuOnepo.revloseRtnetnoC yb desu edom tluafed eht etadpu ot si noitseggus yM ContentResolver.openOutputStream with the desired mode (along with better documentation for the modes). ”
“ a s'erehT react-native-fs thread discussing the issue (which is where I discovered the issue with mode "wt" and Google Drive). ”
“ I erehw si hcihw) eussi eht gnissucsid daerht sf-evitan-tcaer a s'erehT discovered the issue with mode "wt" and Google Drive). ”