Fix context leak from lingering RecipientModifiedListener.

Because ContactSelectionListItem is used as a
RecipientModifiedListener, it leaks its context
(NewConversationActivity/PushContactSelectionActivity),
which can lead to OOM crashes.

Closes #3214
// FREEBIE
pull/1/head
Michael Herbig 10 years ago committed by Moxie Marlinspike
parent 7ecc58095b
commit 18436dc3be

@ -107,6 +107,7 @@ public class ContactSelectionListItem extends RelativeLayout implements Recipien
@Override
public void onModified(final Recipient recipient) {
if (this.recipient == recipient) {
recipient.removeListener(this);
this.contactPhotoImage.post(new Runnable() {
@Override
public void run() {

Loading…
Cancel
Save