FLAG_PRIVILEGED disappears if privileged app is updated and rebooted

Since Kitkat, an app pre-loaded under /system/priv-app/ has
FLAG_PRIVILEGED. However, if the app updated and the device
rebooted, privileged flag is unset from pkgFlags. This patch
fix issue to assign privileged flag when scanning the updated
packages.

Bug: 12640283

Change-Id: Ic24b5882f65dabdfae9cc39da3d68661bed4fc31
Bluetooth: Fix to avoid object leaks during BT OFF

A case where script is running to do BT ON/OFF 2000 times,
Each time while turning off BT FULL_CONNECTED_ASYNC_CHANNEL
is disconnected by Pan Service. HALF_CONNECTED_ASYNC_CHANNEL
is not disconnected, which leads memory leak in Pan Service
object as messenger passed by PanService & ASYNC Channel object.
which are still referred from BT tethering framework code. So GC
does not claim for these objects. HALF_CONNECTED_ASYNC_CHANNEL
should be disconnected, once FULL_CONNECTED_ASYNC_CHANNEL
is disconnected to solve this issue.

Change-Id: I5a7a2beb0169a755cf4f3f37fd0a0ab7d08fd9e5
CRs-Fixed: 591180
Signed-off-by: DHOMD <DHO@dho.im>
Frameworks: Remove RamBar
Frameworks: RamBar (1/3)