diff options
| author | Paul Duffin <paulduffin@google.com> | 2016-04-19 14:14:34 +0100 |
|---|---|---|
| committer | Paul Duffin <paulduffin@google.com> | 2016-04-22 12:35:46 +0100 |
| commit | 01e5d205c2549f9e2500018b41af9618442b3477 (patch) | |
| tree | 4425a47153d34fbf8b1e51d3f346a57305146d6b /include/ScopedJavaUnicodeString.h | |
| parent | 39804fcf43173a98ceecc7e11a0572c2afa9b091 (diff) | |
Make ObjectOutputStream behave as in M when stream is closed
Comments out the call to clear() from close() to prevent the
handle table being reset. That will prevent corruption in the
serialized data which was the cause of this problem.
Logs a warning when writing to a closed stream that the app is
relying on undefined behavior which will change in the next
release. The warning is only logged if the underlying stream
does not itself throw an IOException when attempting to write to
a closed stream. The warning is logged on the first time data is
written to the underlying stream after close() was called.
Writing additional data to the underlying stream will not log
another warning unless close() was called again.
As data is buffered in the ObjectOutputStream writing data to
it may not cause a warning to be logged but the warning will be
logged when the data is flushed.
(cherry picked from commit ec949338f804167b669d47ce86ede15cf2258c56)
Bug: 28159133
Change-Id: I659f7ce9c4bf89379a0703c34fcbf53b42e83bb2
Diffstat (limited to 'include/ScopedJavaUnicodeString.h')
0 files changed, 0 insertions, 0 deletions
