From 5d73bb62ab80a03c0df9dcba12c5248567121dbd Mon Sep 17 00:00:00 2001 From: ticktock35 Date: Mon, 15 Dec 2008 05:14:14 +0000 Subject: [PATCH] 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 --- libopkg/opkg_download.c | 4 ++++ 1 file changed, 4 insertions(+) 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; -- 2.25.1