Hi Dianne

Remains to be said that this can lead to memory leaks because regular 
developers (like me) who assume that using putSerializable uses Java 
serialization in any case might rely on transient fields not being 
serialized/persisted.
If e.g. an object keeps a handle on the Context (in a transient field) this 
context would be leaked, which is a rather big memory leak. Of course we 
should not keep handles on the Context in too many places but then there 
might be other objects as large as Context...
It might be worth mentioning this behavior in the documentation as IMHO 
memory issues are one of the most serious issues Android developers are 
fighting with.

Cheers
Emanuel Moecklin
1gravity LLC

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to