#!/system/bin/sh
if ! applypatch -c EMMC:/dev/block/platform/msm_sdcc.1/by-name/recovery:7323648:3db93973c0a420ee939b0e26ff3a9546540b3ae8; then
  applypatch -b /system/etc/recovery-resource.dat EMMC:/dev/block/platform/msm_sdcc.1/by-name/boot:6582272:b1a0272c75e6ef2959ffd1a1b562f104c74a6892 EMMC:/dev/block/platform/msm_sdcc.1/by-name/recovery 3db93973c0a420ee939b0e26ff3a9546540b3ae8 7323648 b1a0272c75e6ef2959ffd1a1b562f104c74a6892:/system/recovery-from-boot.p && log -t recovery "Installing new recovery image: succeeded" || log -t recovery "Installing new recovery image: failed"
else
  log -t recovery "Recovery image already installed"
fi
