diff options
Diffstat (limited to 'src/util/cleanupdelta.c')
-rw-r--r-- | src/util/cleanupdelta.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/util/cleanupdelta.c b/src/util/cleanupdelta.c index ffcfaba5..71ba3a47 100644 --- a/src/util/cleanupdelta.c +++ b/src/util/cleanupdelta.c @@ -1,7 +1,7 @@ /* * cleanupdelta.c : return list of unused delta in a given sync database * - * Copyright (c) 2010 Pacman Development Team <pacman-dev@archlinux.org> + * Copyright (c) 2011 Pacman Development Team <pacman-dev@archlinux.org> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -17,6 +17,8 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include "config.h" + #include <stdio.h> #include <stdlib.h> #include <string.h> @@ -35,7 +37,7 @@ static void cleanup(int signum) { exit(signum); } -void output_cb(pmloglevel_t level, char *fmt, va_list args) +static void output_cb(pmloglevel_t level, const char *fmt, va_list args) { if(strlen(fmt)) { switch(level) { @@ -49,7 +51,7 @@ void output_cb(pmloglevel_t level, char *fmt, va_list args) } -void checkpkgs(alpm_list_t *pkglist) +static void checkpkgs(alpm_list_t *pkglist) { alpm_list_t *i, *j; for(i = pkglist; i; i = alpm_list_next(i)) { @@ -63,7 +65,7 @@ void checkpkgs(alpm_list_t *pkglist) } } -void checkdbs(char *dbpath, alpm_list_t *dbnames) { +static void checkdbs(char *dbpath, alpm_list_t *dbnames) { char syncdbpath[PATH_MAX]; pmdb_t *db = NULL; alpm_list_t *i; @@ -82,14 +84,14 @@ void checkdbs(char *dbpath, alpm_list_t *dbnames) { } -void usage() { +static void usage(void) { fprintf(stderr, "usage:\n"); fprintf(stderr, "\t%s [-b <pacman db>] core extra ... : check the listed sync databases\n", BASENAME); exit(1); } -int main(int argc, char **argv) +int main(int argc, char *argv[]) { char *dbpath = DBPATH; int a = 1; |