From d5a5a6b512f20cf0b6f72e58ca0479af69044359 Mon Sep 17 00:00:00 2001 From: Andrew Gregory Date: Wed, 13 Feb 2013 18:54:28 -0500 Subject: fix style violations Signed-off-by: Andrew Gregory Signed-off-by: Allan McRae --- lib/libalpm/be_package.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'lib/libalpm/be_package.c') diff --git a/lib/libalpm/be_package.c b/lib/libalpm/be_package.c index 53618934..3b43ed84 100644 --- a/lib/libalpm/be_package.c +++ b/lib/libalpm/be_package.c @@ -542,18 +542,19 @@ int SYMEXPORT alpm_pkg_load(alpm_handle_t *handle, const char *filename, int ful alpm_siglevel_t level, alpm_pkg_t **pkg) { alpm_pkgvalidation_t validation = 0; + char *sigpath; CHECK_HANDLE(handle, return -1); ASSERT(pkg != NULL, RET_ERR(handle, ALPM_ERR_WRONG_ARGS, -1)); - char *sigpath = _alpm_sigpath(handle, filename); + sigpath = _alpm_sigpath(handle, filename); if(sigpath && !_alpm_access(handle, NULL, sigpath, R_OK)) { if(level & ALPM_SIG_PACKAGE) { alpm_list_t *keys = NULL; int fail = 0; unsigned char *sig = NULL; - int len = read_sigfile(sigpath, &sig); + if(len == -1) { _alpm_log(handle, ALPM_LOG_ERROR, _("failed to read signature file: %s\n"), sigpath); -- cgit v1.2.3-24-g4f1b