diff options
author | Timo Teräs <timo.teras@iki.fi> | 2012-02-24 09:00:27 +0200 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2012-02-24 09:00:27 +0200 |
commit | 426954fc7b9d4f99f07389aef15ed61485bd3295 (patch) | |
tree | a01025fab1340ea9a24ada163d8746b552827518 /src | |
parent | e145738acea4bcc3f77ac7573802215a55275d88 (diff) | |
download | apk-tools-426954fc7b9d4f99f07389aef15ed61485bd3295.tar.gz apk-tools-426954fc7b9d4f99f07389aef15ed61485bd3295.tar.bz2 apk-tools-426954fc7b9d4f99f07389aef15ed61485bd3295.tar.xz apk-tools-426954fc7b9d4f99f07389aef15ed61485bd3295.zip |
verify: report only bad packages with -q
fixes #1010
Diffstat (limited to 'src')
-rw-r--r-- | src/verify.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/verify.c b/src/verify.c index 6903dcd..cfb800a 100644 --- a/src/verify.c +++ b/src/verify.c @@ -28,7 +28,10 @@ static int verify_main(void *ctx, struct apk_database *db, int argc, char **argv is = apk_bstream_gunzip_mpart(apk_bstream_from_file(AT_FDCWD, argv[i]), apk_sign_ctx_mpart_cb, &sctx); if (is == NULL) { - apk_error("%s: %s", strerror(errno), argv[i]); + if (apk_verbosity >= 1) + apk_error("%s: %s", argv[i], strerror(errno)); + else + printf("%s\n", argv[i]); apk_sign_ctx_free(&sctx); rc++; continue; @@ -39,7 +42,9 @@ static int verify_main(void *ctx, struct apk_database *db, int argc, char **argv if (apk_verbosity >= 1) apk_message("%s: %d - %s", argv[i], r, ok ? "OK" : - sctx.data_verified ? "UNTRUSTED" : "FAILED"); + !sctx.control_verified ? "UNTRUSTED" : "FAILED"); + else if (!ok) + printf("%s\n", argv[i]); if (!ok) rc++; apk_sign_ctx_free(&sctx); |