Use app context to avoid memory leaks

Bug: 31581886
Test: manual
Change-Id: I375ed953665e431cc8f15a2ceefacabd9055269c
1 file changed