1
0
mirror of https://github.com/moparisthebest/pacman synced 2024-08-13 17:03:46 -04:00
pacman/lib/libalpm
Dan McGee 33240e87b9 Fix double filelist issue when upgrading a package
Due to the way we funk around with package data loading, we had a condition
where the filelist got doubled up because it was loaded twice.

Packages are originally loaded with INFRQ_BASE. In an upgrade/sync, the
package is checked for file conflicts next, leaving us in an "INFRQ_BASE |
INFRQ_FILES" state. Later, when committing a single package, we have an
explicit call to _alpm_local_db_read() with INFRQ_ALL as the level. Because
the package's level did not match this, we skipped over our previous "does
the incoming level match where I'm at" shortcut, and continued to load
things again, because of a lack of fine-grained checking for each of DESC,
FILES, and INSTALL.

The end result is we loaded the filelist twice, causing our remove logic to
iterate twice over the installed files, spewing a bunch of "cannot find file
X" messages.

Fix the problem by doing a bit more bitmasking logic throughout the load
method, and also fix the sanity check at the beginning of the function- this
should *only* be used for local packages as opposed to the "not a package"
check that was there before.

A debug log message was added to upgraderemove as well to match the one
already in the normal remove codepath.

Signed-off-by: Dan McGee <dan@archlinux.org>
2011-01-11 21:16:39 -06:00
..
po Separate be_files into be_sync and be_local 2010-10-14 13:17:38 +10:00
.gitignore Remove unnecessary entries from .gitignore files 2007-07-16 16:49:28 -04:00
add.c Remove need for floating point division in backend 2011-01-10 10:49:55 -06:00
add.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
alpm_list.c Use size_t for alpm_list sizes 2011-01-07 21:15:46 -06:00
alpm_list.h Use size_t for alpm_list sizes 2011-01-07 21:15:46 -06:00
alpm.c Update copyright years for 2011 2011-01-07 18:47:37 -06:00
alpm.h Use size_t for alpm_list sizes 2011-01-07 21:15:46 -06:00
backup.c Update copyright years for 2011 2011-01-07 18:47:37 -06:00
backup.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
be_local.c Fix double filelist issue when upgrading a package 2011-01-11 21:16:39 -06:00
be_package.c libalpm/be_package.c: fix small memleak 2011-01-07 21:27:39 -06:00
be_sync.c Use size_t for alpm_list sizes 2011-01-07 21:15:46 -06:00
conflict.c Remove need for floating point division in backend 2011-01-10 10:49:55 -06:00
conflict.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
db.c Fix some more simple conversion "errors" 2011-01-07 21:15:47 -06:00
db.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
delta.c Update copyright years for 2011 2011-01-07 18:47:37 -06:00
delta.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
deps.c Fix some more simple conversion "errors" 2011-01-07 21:15:47 -06:00
deps.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
diskspace.c Ensure we use local package when calculating removed size 2011-01-10 10:50:03 -06:00
diskspace.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
dload.c Fix some more simple conversion "errors" 2011-01-07 21:15:47 -06:00
dload.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
error.c Update copyright years for 2011 2011-01-07 18:47:37 -06:00
graph.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
group.c Update copyright years for 2011 2011-01-07 18:47:37 -06:00
group.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
handle.c Update copyright years for 2011 2011-01-07 18:47:37 -06:00
handle.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
log.c Update copyright years for 2011 2011-01-07 18:47:37 -06:00
log.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
Makefile.am Prototype disk space checking functionality 2010-12-12 20:29:37 -06:00
md5.c libalpm md5: use larger and dynamic buffer 2010-09-02 10:33:21 -05:00
md5.h libalpm/md5: Fix license header 2008-06-03 21:31:31 -05:00
package.c Update copyright years for 2011 2011-01-07 18:47:37 -06:00
package.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
remove.c Fix double filelist issue when upgrading a package 2011-01-11 21:16:39 -06:00
remove.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
sync.c Use size_t for alpm_list sizes 2011-01-07 21:15:46 -06:00
sync.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
trans.c Update copyright years for 2011 2011-01-07 18:47:37 -06:00
trans.h Update copyright years for 2011 2011-01-07 18:47:37 -06:00
util.c Fix some more simple conversion "errors" 2011-01-07 21:15:47 -06:00
util.h Refactor old date parsing into single method 2011-01-07 20:55:05 -06:00
version.c Update copyright years for 2011 2011-01-07 18:47:37 -06:00