Not sure if you guys are aware of this but pay attention if you are extending
FilterOutputStream. One would expect FilterOutputStream implementation to filter all
methods directly to some underlying stream. However, rather than filter byte array writes
directly to the underlying stream FilterOutputStream modifies the expected behaviour to
write individual bytes instead.
http://www.redirecttonull.com/?p=186
Regards,
Vladimir