JavaMemoryModel: Unsynchronized gettes

From: Doron Rajwan (
Date: Wed Apr 28 2004 - 07:16:58 EDT

Tiger beta1 libs has lots of unsynchronized gettes.

ByteArrayOutputStream, for example, has all update
methods synchronized, but all the getters, such as
size(), are not.

1. Is this a bug, or maybe this class was not suppose
to be thread-safe in the first place?

2. Does FindBugs check for this?


Doron Rajwan,

JavaMemoryModel mailing list -

This archive was generated by hypermail 2b29 : Thu Oct 13 2005 - 07:01:06 EDT