summaryrefslogtreecommitdiffstats
path: root/lib/libalpm/error.c
diff options
context:
space:
mode:
authorXavier Chantry <shiningxc@gmail.com>2009-09-15 16:07:25 +0200
committerDan McGee <dan@archlinux.org>2009-09-20 18:56:46 +0200
commitf4809dcc9c27ac614e2a3381d4ecd8661beec8de (patch)
treed680c5144e14ec021523d7d9e58edb1b4cc78420 /lib/libalpm/error.c
parent95cb4b6874424c7109df0f8cebefc17d3756d65f (diff)
downloadpacman-f4809dcc9c27ac614e2a3381d4ecd8661beec8de.tar.gz
pacman-f4809dcc9c27ac614e2a3381d4ecd8661beec8de.tar.xz
sync.c : duplicate the target before modifying it
It was probably a bad idea to modify the target directly in case of repo/pkg syntax. Duplicating it also allows us to keep the original target string, which is more informative when printing errors. Also remove a duplicated error message from libalpm, and improve the message already returned to the frontend. $ pacman -S foo/bar before error: repository 'foo' not found error: 'bar': no such repository after error: 'foo/bar': could not find repository for target Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'lib/libalpm/error.c')
-rw-r--r--lib/libalpm/error.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libalpm/error.c b/lib/libalpm/error.c
index 6ff1d675..ae19786e 100644
--- a/lib/libalpm/error.c
+++ b/lib/libalpm/error.c
@@ -120,7 +120,7 @@ const char SYMEXPORT *alpm_strerror(int err)
case PM_ERR_PKG_INVALID_ARCH:
return _("package architecture is not valid");
case PM_ERR_PKG_REPO_NOT_FOUND:
- return _("no such repository");
+ return _("could not find repository for target");
/* Deltas */
case PM_ERR_DLT_INVALID:
return _("invalid or corrupted delta");