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.
Cherry-picked from AOSP: https://android-review.googlesource.com/#/c/79511/

Change-Id: Ic24b5882f65dabdfae9cc39da3d68661bed4fc31