Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/lib/libalpm
diff options
context:
space:
mode:
authorAurelien Foret <aurelien@archlinux.org>2006-03-21 19:38:00 +0000
committerAurelien Foret <aurelien@archlinux.org>2006-03-21 19:38:00 +0000
commit839a64df411115599bdef7a5c14d180111842523 (patch)
tree135a50f356637a81207d662d23eb5101a4450a2c /lib/libalpm
parentad2c7463c9b3ccf35ed40d8fa4cc21309048bdbc (diff)
fixed a regression (patch from VMiklos <vmiklos@frugalware.org>)
Diffstat (limited to 'lib/libalpm')
-rw-r--r--lib/libalpm/alpm.c4
-rw-r--r--lib/libalpm/be_files.c2
2 files changed, 2 insertions, 4 deletions
diff --git a/lib/libalpm/alpm.c b/lib/libalpm/alpm.c
index dddeaeff..70b1bb78 100644
--- a/lib/libalpm/alpm.c
+++ b/lib/libalpm/alpm.c
@@ -292,7 +292,6 @@ void *alpm_db_getinfo(PM_DB *db, unsigned char parm)
int alpm_db_update(PM_DB *db, char *archive)
{
PMList *lp;
- char path[PATH_MAX];
/* Sanity checks */
ASSERT(handle != NULL, RET_ERR(PM_ERR_HANDLE_NULL, -1));
@@ -323,9 +322,8 @@ int alpm_db_update(PM_DB *db, char *archive)
/* ORE
we should not simply unpack the archive, but better parse it and
db_write each entry (see sync_load_dbarchive to get archive content) */
- snprintf(path, PATH_MAX, "%s/%s", db->path, db->treename);
_alpm_log(PM_LOG_FLOW2, "unpacking %s", archive);
- if(_alpm_unpack(archive, path, NULL)) {
+ if(_alpm_unpack(archive, db->path, NULL)) {
RET_ERR(PM_ERR_SYSTEM, -1);
}
diff --git a/lib/libalpm/be_files.c b/lib/libalpm/be_files.c
index c584b276..0a648223 100644
--- a/lib/libalpm/be_files.c
+++ b/lib/libalpm/be_files.c
@@ -330,7 +330,7 @@ int _alpm_db_read(pmdb_t *db, unsigned int inforeq, pmpkg_t *info)
/* INSTALL */
if(inforeq & INFRQ_SCRIPLET) {
- snprintf(path, PATH_MAX, "%s/%s/%s-%s/install", db->path, db->treename, info->name, info->version);
+ snprintf(path, PATH_MAX, "%s/%s-%s/install", db->path, info->name, info->version);
if(!stat(path, &buf)) {
info->scriptlet = 1;
}