diff options
author | ticktock35 <ticktock35@e8e0d7a0-c8d9-11dd-a880-a1081c7ac358> | 2008-12-15 00:14:14 (EST) |
---|---|---|
committer | ticktock35 <ticktock35@e8e0d7a0-c8d9-11dd-a880-a1081c7ac358> | 2008-12-15 00:14:14 (EST) |
commit | 5d73bb62ab80a03c0df9dcba12c5248567121dbd (patch) | |
tree | 2f5268415739fc579468e3e8f95418223ff9caba | |
parent | 871744d4c3437d0de1294343b0fe4202f2111def (diff) |
opkg: add some extra error checks to opkg_verify_file()
git-svn-id: http://opkg.googlecode.com/svn/trunk@96 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
-rw-r--r-- | libopkg/opkg_download.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libopkg/opkg_download.c b/libopkg/opkg_download.c index 428cad5..6acdc32 100644 --- a/libopkg/opkg_download.c +++ b/libopkg/opkg_download.c @@ -252,8 +252,12 @@ opkg_verify_file (opkg_conf_t *conf, char *text_file, char *sig_file) return -1; err = gpgme_op_verify (ctx, sig, text, NULL); + if (err) + return -1; result = gpgme_op_verify_result (ctx); + if (!result) + return -1; /* see if any of the signitures matched */ s = result->signatures; |