manager.sh: add ro.boot.vbmeta.size + ro.product.ab_ota_partitions to vbmeta check

ro.boot.vbmeta.device doesn't seem to be in use on all A/B devices
This commit is contained in:
Chris Renshaw 2023-08-28 04:45:14 -03:00 committed by GitHub
parent eadb0307fa
commit 474268a0af
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 3 deletions

View File

@ -202,10 +202,11 @@ get_flags() {
ISENCRYPTED=false
[ "$(getprop ro.crypto.state)" = "encrypted" ] && ISENCRYPTED=true
KEEPFORCEENCRYPT=$ISENCRYPTED
if [ -n "$(getprop ro.boot.vbmeta.device)" ]; then
VBMETAEXIST=false
if [ -n "$(getprop ro.boot.vbmeta.device)" -o -n "$(getprop ro.boot.vbmeta.size)" ]; then
VBMETAEXIST=true
elif getprop ro.product.ab_ota_partitions | grep -wq vbmeta; then
VBMETAEXIST=true
else
VBMETAEXIST=false
fi
# Preset PATCHVBMETAFLAG to false in the non-root case
PATCHVBMETAFLAG=false