index : pacman | |
Archlinux32 fork of pacman | gitolite user |
summaryrefslogtreecommitdiff |
author | Aurelien Foret <aurelien@archlinux.org> | 2005-03-28 08:21:17 +0000 |
---|---|---|
committer | Aurelien Foret <aurelien@archlinux.org> | 2005-03-28 08:21:17 +0000 |
commit | 56917dc30493680219e0eceddbf178242522f11d (patch) | |
tree | 4dd1c8eeff9122a6de3473c2395ac6c5ea13f225 /lib/libalpm/package.c | |
parent | 9c17eb88f09bfbead0c7b9c63dd47aa6fcfdfda6 (diff) |
-rw-r--r-- | lib/libalpm/package.c | 9 |
diff --git a/lib/libalpm/package.c b/lib/libalpm/package.c index 4e56b763..418fefb1 100644 --- a/lib/libalpm/package.c +++ b/lib/libalpm/package.c @@ -33,6 +33,7 @@ #include "error.h" #include "list.h" #include "package.h" +#include "alpm.h" pmpkg_t *pkg_new() { @@ -118,12 +119,12 @@ static int parse_descfile(char *descfile, pmpkg_t *info, int output) continue; } if(output) { - printf("%s\n", line); + _alpm_log(PM_LOG_DEBUG, "%s", line); } ptr = line; key = strsep(&ptr, "="); if(key == NULL || ptr == NULL) { - fprintf(stderr, "%s: syntax error in description file line %d\n", + _alpm_log(PM_LOG_ERROR, "%s: syntax error in description file line %d", info->name[0] != '\0' ? info->name : "error", linenum); } else { _alpm_strtrim(key); @@ -164,7 +165,7 @@ static int parse_descfile(char *descfile, pmpkg_t *info, int output) } else if(!strcmp(key, "BACKUP")) { info->backup = pm_list_add(info->backup, strdup(ptr)); } else { - fprintf(stderr, "%s: syntax error in description file line %d\n", + _alpm_log(PM_LOG_ERROR, "%s: syntax error in description file line %d", info->name[0] != '\0' ? info->name : "error", linenum); } } @@ -257,7 +258,7 @@ pmpkg_t *pkg_load(char *pkgfile) FREE(str); fclose(fp); if(unlink(fn)) { - _alpm_log(PM_LOG_WARNING, "could not remove tempfile %s\n", fn); + _alpm_log(PM_LOG_WARNING, "could not remove tempfile %s", fn); } FREE(fn); filelist = 1; |