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

Commit 4b588cf7 authored by Kelvin Zhang's avatar Kelvin Zhang
Browse files

Skip signing key check in some cases

Test: th
Bug: 205657204

Change-Id: I3a2fc886cfb3fe3d53619bfb8fe84aa799d80de3
parent 96f398c0
Loading
Loading
Loading
Loading
+55 −53
Original line number Diff line number Diff line
@@ -1473,6 +1473,11 @@ def main(argv):
          "build/make/target/product/security/testkey")
    # Get signing keys
    OPTIONS.key_passwords = common.GetKeyPasswords([OPTIONS.package_key])

    # Only check for existence of key file if using the default signer.
    # Because the custom signer might not need the key file AT all.
    # b/191704641
    if not OPTIONS.signapk_path:
      private_key_path = OPTIONS.package_key + OPTIONS.private_key_suffix
      if not os.path.exists(private_key_path):
        raise common.ExternalError(
@@ -1531,8 +1536,5 @@ if __name__ == '__main__':
  try:
    common.CloseInheritedPipes()
    main(sys.argv[1:])
  except common.ExternalError:
    logger.exception("\n   ERROR:\n")
    sys.exit(1)
  finally:
    common.Cleanup()