summaryrefslogtreecommitdiff
path: root/src/adb.c
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2021-08-23 15:17:11 +0300
committerTimo Teräs <timo.teras@iki.fi>2021-08-23 17:02:50 +0300
commit99fa1fb797995fb5857f7604f90033b08ebf430c (patch)
tree726ae7a26b57ca44a1806c025335a31d8667103d /src/adb.c
parent72d8cb8937c5ffa7016ef3fdfeb17c5abae97b61 (diff)
downloadapk-tools-99fa1fb797995fb5857f7604f90033b08ebf430c.tar.gz
apk-tools-99fa1fb797995fb5857f7604f90033b08ebf430c.tar.bz2
apk-tools-99fa1fb797995fb5857f7604f90033b08ebf430c.tar.xz
apk-tools-99fa1fb797995fb5857f7604f90033b08ebf430c.zip
trust: always use have valid struct apk_trust *
Make sure we always have valid struct apk_trust * for code using it. Load the signing keys directly when being specified to produce sane error message if loading them fails.
Diffstat (limited to 'src/adb.c')
-rw-r--r--src/adb.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/src/adb.c b/src/adb.c
index 53a82cd..5607af6 100644
--- a/src/adb.c
+++ b/src/adb.c
@@ -1103,8 +1103,6 @@ int adb_trust_write_signatures(struct apk_trust *trust, struct adb *db, struct a
size_t siglen;
int r;
- if (IS_ERR(trust)) return PTR_ERR(trust);
-
if (!vfy) {
vfy = alloca(sizeof *vfy);
memset(vfy, 0, sizeof *vfy);