Przemyslaw Szczepaniak fcf671be89 Fix EBADF in TTS synthesizeToFile method.
Recent TTS change altered how the TextToSpeech.synthesizeToFile method
operates. Previously, synthesis service was responsible for creating
output file. Now, client API creates a file and then sends opened file
descriptor using ParcelFileDescriptor.

On service side, I forgot to keep a reference to a ParcelFileDescriptor object.
When GC was removing it, it was closing underlying file descriptor, resulting
in a EBADF error for all following writes to the output file.

This change makes use of a ParcelFileDescriptor.AutoCloseOutputStream to keep a
reference to the ParcelFileDescriptor. It will be referenced until we are done
with writing.

Change-Id: I8327af0eaeabaebfbbd8816d959783e89086a7c5
2013-03-06 09:27:11 +00:00
2013-02-28 16:43:23 -08:00
2013-02-15 12:47:40 -08:00
2013-02-14 12:06:51 -08:00
2012-12-12 11:27:44 +08:00
2013-03-05 10:28:05 -08:00
Description
No description provided
5.1 GiB
Languages
Java 77.3%
Kotlin 9.2%
PowerBuilder 6.6%
C++ 5.5%
AIDL 1%