Android 8.1.0 Release 81 (6780335)
-----BEGIN PGP SIGNATURE-----

iF0EABECAB0WIQRDQNE1cO+UXoOBCWTorT+BmrEOeAUCX3uqXQAKCRDorT+BmrEO
eF1RAKCQB2LN7GjUqvZzM5iDml56/0Z+SwCdFQR8w8zlpSndhqAL6YK+2wYUj+U=
=cD0A
-----END PGP SIGNATURE-----
Fix potential use-after-free issue

NuPlayerListener passed this out of its constructor to
IStreamSource->setListener, and it would get wrapped in a smart pointer,
then free'd when that method returned.

Move the setListener call after instantiation of NuPlayerListener to
avoid passing this out of the NuPlayerListener constructor.

Test: tested in presubmit
Bug: 151456667
Change-Id: I996d9ad9eaf0e52992b7f9e10fd94a94c350ad73
(cherry picked from commit aad519df7fe3b69c8247669ea77ce339a44e8c51)
(cherry picked from commit 6aaef5a99f15da847a8c55a137bfc6263829e8ff)
2 files changed