summaryrefslogtreecommitdiffstats
path: root/src/pacman/remove.c
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2007-04-26 22:23:59 +0200
committerDan McGee <dan@archlinux.org>2007-04-26 22:23:59 +0200
commit8d46cf6651e4593786621be62216c6ef9f03a172 (patch)
tree0055ed9889b5b6d6e02869d46179fd60f3cc8d2e /src/pacman/remove.c
parentf2dabeb19f79544775e8f369710f267a6d087b24 (diff)
downloadpacman-8d46cf6651e4593786621be62216c6ef9f03a172.tar.gz
pacman-8d46cf6651e4593786621be62216c6ef9f03a172.tar.xz
Remove ERR calls from the code
All ERR() calls have been replaced with fprintf(stderr, ...). Still to be done- fix all the newline issues that are sure to pop up. What fun! Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'src/pacman/remove.c')
-rw-r--r--src/pacman/remove.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/src/pacman/remove.c b/src/pacman/remove.c
index 32570927..aef30144 100644
--- a/src/pacman/remove.c
+++ b/src/pacman/remove.c
@@ -83,7 +83,8 @@ int pacman_remove(alpm_list_t *targets)
/* Step 1: create a new transaction */
if(alpm_trans_init(PM_TRANS_TYPE_REMOVE, config->flags,
cb_trans_evt, cb_trans_conv, cb_trans_progress) == -1) {
- ERR(NL, _("failed to init transaction (%s)\n"), alpm_strerror(pm_errno));
+ fprintf(stderr, _("error: failed to init transaction (%s)\n"),
+ alpm_strerror(pm_errno));
if(pm_errno == PM_ERR_HANDLE_LOCK) {
printf(_(" if you're sure a package manager is not already\n"
" running, you can remove %s%s.\n"),
@@ -99,8 +100,8 @@ int pacman_remove(alpm_list_t *targets)
char *targ = alpm_list_getdata(i);
if(alpm_trans_addtarget(targ) == -1) {
printf("failed.\n");
- ERR(NL, _("failed to add target '%s' (%s)\n"), targ,
- alpm_strerror(pm_errno));
+ fprintf(stderr, _("error: failed to add target '%s' (%s)\n"), targ,
+ alpm_strerror(pm_errno));
retval = 1;
goto cleanup;
}
@@ -108,7 +109,8 @@ int pacman_remove(alpm_list_t *targets)
/* Step 2: prepare the transaction based on its type, targets and flags */
if(alpm_trans_prepare(&data) == -1) {
- ERR(NL, _("failed to prepare transaction (%s)\n"), alpm_strerror(pm_errno));
+ fprintf(stderr, _("error: failed to prepare transaction (%s)\n"),
+ alpm_strerror(pm_errno));
switch(pm_errno) {
case PM_ERR_UNSATISFIED_DEPS:
for(i = data; i; i = alpm_list_next(i)) {
@@ -148,7 +150,8 @@ int pacman_remove(alpm_list_t *targets)
/* Step 3: actually perform the removal */
if(alpm_trans_commit(NULL) == -1) {
- ERR(NL, _("failed to commit transaction (%s)\n"), alpm_strerror(pm_errno));
+ fprintf(stderr, _("error: failed to commit transaction (%s)\n"),
+ alpm_strerror(pm_errno));
retval = 1;
goto cleanup;
}
@@ -157,7 +160,8 @@ int pacman_remove(alpm_list_t *targets)
cleanup:
FREELIST(finaltargs);
if(alpm_trans_release() == -1) {
- ERR(NL, _("failed to release transaction (%s)\n"), alpm_strerror(pm_errno));
+ fprintf(stderr, _("error: failed to release transaction (%s)\n"),
+ alpm_strerror(pm_errno));
retval = 1;
}