Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5a5d96a8 authored by Brint E. Kriebel's avatar Brint E. Kriebel
Browse files

ota_from_target_files: Fix path for SkipNextActionIfTargetExists

Without the leading forward slash, the check always fails.

Change-Id: I57320c20ca2b384713182082b1ad5321d78dbb2b
parent c09c72ab
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -1051,7 +1051,7 @@ class FileDifference:
    so_far = 0
    for tf, sf, size, patch_sha in self.patch_list:
      if tf.name != sf.name:
        script.SkipNextActionIfTargetExists(tf.name, tf.sha1)
        script.SkipNextActionIfTargetExists("/"+tf.name, tf.sha1)
      script.PatchCheck("/"+sf.name, tf.sha1, sf.sha1)
      so_far += sf.size
    return so_far
@@ -1081,7 +1081,7 @@ class FileDifference:
        deferred_patch_list.append(item)
        continue
      if (sf.name != tf.name):
        script.SkipNextActionIfTargetExists(tf.name, tf.sha1)
        script.SkipNextActionIfTargetExists("/"+tf.name, tf.sha1)
      script.ApplyPatch("/"+sf.name, "-", tf.size, tf.sha1, sf.sha1, "patch/"+sf.name+".p")
      so_far += tf.size
      script.SetProgress(so_far / total_patch_size)