Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2007-11-21 11:25:50 -0600
committerDan McGee <dan@archlinux.org>2007-11-21 11:51:17 -0600
commitf5d2150e9db9205a9f208d4144b6d0381f877ad3 (patch)
treed14b63e9d6f4f7dfb664f8e22c4c21bc25aa24a8 /lib
parent0144b2ed29b3e3ae09fd8caeeffdadc10322cc1c (diff)
Remove -F/--freshen operation
This operation made sense in the days before sync DBs existed, but it no longer has the same usefulness it once did. Signed-off-by: Dan McGee <dan@archlinux.org> Signed-off-by: Chantry Xavier <shiningxc@gmail.com> Signed-off-by: Nagy Gabor <ngaba@bibl.u-szeged.hu> Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/libalpm/add.c13
-rw-r--r--lib/libalpm/alpm.h2
2 files changed, 3 insertions, 12 deletions
diff --git a/lib/libalpm/add.c b/lib/libalpm/add.c
index e6efe2d7..0b40f957 100644
--- a/lib/libalpm/add.c
+++ b/lib/libalpm/add.c
@@ -76,19 +76,10 @@ int _alpm_add_loadtarget(pmtrans_t *trans, pmdb_t *db, char *name)
pm_errno = PM_ERR_PKG_INSTALLED;
goto error;
}
- } else {
- if(trans->flags & PM_TRANS_FLAG_FRESHEN) {
- /* only upgrade/install this package if it is already installed and at a lesser version */
- pmpkg_t *dummy = _alpm_db_get_pkgfromcache(db, pkgname);
- if(dummy == NULL || _alpm_versioncmp(dummy->version, pkgver) >= 0) {
- pm_errno = PM_ERR_PKG_CANT_FRESH;
- goto error;
- }
- }
}
- /* check if an older version of said package is already in transaction packages.
- * if so, replace it in the list */
+ /* check if an older version of said package is already in transaction
+ * packages. if so, replace it in the list */
for(i = trans->packages; i; i = i->next) {
pmpkg_t *pkg = i->data;
if(strcmp(pkg->name, pkgname) == 0) {
diff --git a/lib/libalpm/alpm.h b/lib/libalpm/alpm.h
index b56f5758..76c7208a 100644
--- a/lib/libalpm/alpm.h
+++ b/lib/libalpm/alpm.h
@@ -271,7 +271,7 @@ typedef enum _pmtransflag_t {
PM_TRANS_FLAG_NODEPS = 0x01,
PM_TRANS_FLAG_FORCE = 0x02,
PM_TRANS_FLAG_NOSAVE = 0x04,
- PM_TRANS_FLAG_FRESHEN = 0x08,
+ /* 0x08 flag can go here */
PM_TRANS_FLAG_CASCADE = 0x10,
PM_TRANS_FLAG_RECURSE = 0x20,
PM_TRANS_FLAG_DBONLY = 0x40,