summaryrefslogtreecommitdiffabout
path: root/src/verify.c
authorSergey Poznyakoff <gray@gnu.org.ua>2010-01-03 09:44:34 (GMT)
committer Sergey Poznyakoff <gray@gnu.org.ua>2010-01-03 09:49:20 (GMT)
commitc2cbf4e863a8f3a5081357d4b48f54cec2cd5d69 (patch) (side-by-side diff)
tree93711f398c585fcc8ac0b19bbcfe15b79f4c6b73 /src/verify.c
parenta2489ce17e9c9a03b649d5b63183d4f830c639a1 (diff)
downloadwydawca-c2cbf4e863a8f3a5081357d4b48f54cec2cd5d69.tar.gz
wydawca-c2cbf4e863a8f3a5081357d4b48f54cec2cd5d69.tar.bz2
Do not pass spool as a separate parameter, register it early in the triplet.
* src/directive.c (process_directives): Remove spool parameter. * src/gpg.c (verify_directive_signature) (verify_detached_signature): Remove spool parameter. * src/process.c (scan_spool_unlocked): Update call to register_file. * src/triplet.c (register_file): Take spool ptr as second argument. (triplet_processor): Ignore proc_data. (enumerate_triplets): Pass NULL as proc_data. * src/verify.c (verify_directive_file): Remove spool parameter. * src/wydawca.h (ASGN_SPOOL): New macro. (register_file, verify_directive_file) (verify_directive_signature, verify_detached_signature) (process_directives): Remove spool parameter. * src/getopt.m4 (print_help): Minor fix.
Diffstat (limited to 'src/verify.c') (more/less context) (ignore whitespace changes)
-rw-r--r--src/verify.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/verify.c b/src/verify.c
index 7520466..01c61ea 100644
--- a/src/verify.c
+++ b/src/verify.c
@@ -193,15 +193,18 @@ uploader_find_frp (struct uploader_info *list, const char *fpr)
}
int
-verify_directive_file (struct file_triplet *trp, const struct spool *spool)
+verify_directive_file (struct file_triplet *trp)
{
char *command;
- struct dictionary *dict = spool->dictionary[project_uploader_dict];
int rc;
void *md;
-
size_t nrows, ncols, i;
struct uploader_info *head, *tail;
+ const struct spool *spool;
+ struct dictionary *dict;
+
+ ASGN_SPOOL (spool, trp, return 1);
+ dict = spool->dictionary[project_uploader_dict];
if (!trp->file[file_directive].name)
return 1;
@@ -301,7 +304,7 @@ verify_directive_file (struct file_triplet *trp, const struct spool *spool)
trp->uploader_list = head;
trp->uploader = NULL;
- if (verify_directive_signature (trp, spool))
+ if (verify_directive_signature (trp))
{
/*FIXME: Update stats */
logmsg (LOG_ERR, _("invalid signature for %s"),

Return to:

Send suggestions and report system problems to the System administrator.