summaryrefslogtreecommitdiff
path: root/lib/libalpm/signing.c
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2011-04-15 19:30:11 -0500
committerDan McGee <dan@archlinux.org>2011-04-20 20:11:26 -0500
commit442e1420f95ecc6fd1967677c1be5dfed6584542 (patch)
tree42c26edf4408acad0580c543262aee51e8e91c95 /lib/libalpm/signing.c
parent3c5661ec3cd5cdf2f1c3101d90789c83786a6897 (diff)
downloadpacman-442e1420f95ecc6fd1967677c1be5dfed6584542.tar.xz
Rename gpgsig struct fields for clarity
Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'lib/libalpm/signing.c')
-rw-r--r--lib/libalpm/signing.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/libalpm/signing.c b/lib/libalpm/signing.c
index 51c4f4ce..9d4fd076 100644
--- a/lib/libalpm/signing.c
+++ b/lib/libalpm/signing.c
@@ -109,7 +109,7 @@ int _alpm_gpgme_checksig(const char *path, const pmpgpsig_t *sig)
ALPM_LOG_FUNC;
- if(!sig || !sig->rawdata) {
+ if(!sig || !sig->data) {
RET_ERR(PM_ERR_SIG_UNKNOWN, -1);
}
if(!path || access(path, R_OK) != 0) {
@@ -140,7 +140,7 @@ int _alpm_gpgme_checksig(const char *path, const pmpgpsig_t *sig)
CHECK_ERR();
/* next create data object for the signature */
- err = gpgme_data_new_from_mem(&sigdata, (char *)sig->rawdata, sig->rawlen, 0);
+ err = gpgme_data_new_from_mem(&sigdata, (char *)sig->data, sig->len, 0);
CHECK_ERR();
/* here's where the magic happens */
@@ -227,18 +227,18 @@ int _alpm_load_signature(const char *file, pmpgpsig_t *pgpsig) {
free(sigfile);
return ret;
}
- CALLOC(pgpsig->rawdata, st.st_size, sizeof(unsigned char),
+ CALLOC(pgpsig->data, st.st_size, sizeof(unsigned char),
RET_ERR(PM_ERR_MEMORY, -1));
- bytes_read = fread(pgpsig->rawdata, sizeof(char), st.st_size, f);
+ bytes_read = fread(pgpsig->data, sizeof(char), st.st_size, f);
if(bytes_read == (size_t)st.st_size) {
- pgpsig->rawlen = bytes_read;
+ pgpsig->len = bytes_read;
_alpm_log(PM_LOG_DEBUG, "loaded gpg signature file, location %s\n",
sigfile);
ret = 0;
} else {
_alpm_log(PM_LOG_WARNING, _("Failed reading PGP signature file %s"),
sigfile);
- FREE(pgpsig->rawdata);
+ FREE(pgpsig->data);
}
fclose(f);