1
0
mirror of https://github.com/moparisthebest/pacman synced 2024-12-22 15:58:50 -05:00
pacman/lib/libalpm
Olivier Brunel 1e3c088c2e alpm: Fix wrong xferred/total sizes when resuming downloads
When a package is already partially downloaded in the cache, its download
size will only be of what's left to be downloaded. Since pkg->download_size
is what's used when calculating the total download size for the totaldl
callback, same thing apply.

However, the download progress callback was including this initial size,
which would thus lead to invalid values (and percentage) used in frontends.
That is, the progress bar could e.g. go further than 100%

In the case of pacman, there is a sanity check for different historical
reason (44a57c89), so before the possible "overflow" was noticed, the total
download size/progress reported was wrong. Once caught, the TotalDownload
option was ignored and it would use individual file download values as
fallback instead.

Signed-off-by: Olivier Brunel <jjk@jjacky.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
2014-10-02 22:50:17 +10:00
..
po Do not remove source code references in PO/POT files 2014-02-02 16:32:55 +10:00
.gitignore libalpm: add pkg-config file 2012-04-25 20:02:36 -04:00
add.c move _alpm_lstat into util-common 2014-08-03 18:46:32 +10:00
add.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
alpm_list.c Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
alpm_list.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
alpm.c Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
alpm.h Add --assume-installed option 2014-09-30 22:33:26 +10:00
backup.c Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
backup.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
base64.c base64.c: comment out unused variable 2014-01-15 15:54:56 +10:00
base64.h base64: don't compile base64_encode() function 2011-10-17 12:03:02 -05:00
be_local.c libalpm: export alpm_splitdep as alpm_dep_from_depstring and alpm_dep_free 2014-09-30 22:20:53 +10:00
be_package.c libalpm: export alpm_splitdep as alpm_dep_from_depstring and alpm_dep_free 2014-09-30 22:20:53 +10:00
be_sync.c libalpm: export alpm_splitdep as alpm_dep_from_depstring and alpm_dep_free 2014-09-30 22:20:53 +10:00
conflict.c fix improper FREELIST calls 2014-09-16 20:03:33 +10:00
conflict.h alpm: export *_free functions 2014-02-04 13:48:37 +10:00
db.c register_syncdb: reject db names that contain / 2014-05-04 16:14:44 +10:00
db.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
delta.c Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
delta.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
deps.c Add --assume-installed option 2014-09-30 22:33:26 +10:00
deps.h libalpm: export alpm_splitdep as alpm_dep_from_depstring and alpm_dep_free 2014-09-30 22:20:53 +10:00
diskspace.c replace strdup with STRDUP 2014-08-04 14:23:58 +10:00
diskspace.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
dload.c alpm: Fix wrong xferred/total sizes when resuming downloads 2014-10-02 22:50:17 +10:00
dload.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
error.c Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
filelist.c filelist_intersection: manually compare paths 2014-08-03 18:46:31 +10:00
filelist.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
graph.c Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
graph.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
group.c Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
group.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
handle.c _alpm_key_in_keychain: cache known keys 2014-10-01 09:12:54 +10:00
handle.h _alpm_key_in_keychain: cache known keys 2014-10-01 09:12:54 +10:00
libalpm.pc.in Use libalpm version in pkg-config file 2013-04-26 12:43:53 +10:00
libarchive-compat.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
log.c Revert "Remove log_cb, add ALPM_EVENT_LOG instead" 2014-09-30 12:56:21 +10:00
log.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
Makefile.am Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
md5.c Use 32-bit wide integer type in PolarSSL code 2012-01-07 11:27:41 -06:00
md5.h Update MD5 routines with changes from PolarSSL 2011-08-11 20:17:21 -05:00
package.c libalpm: export alpm_splitdep as alpm_dep_from_depstring and alpm_dep_free 2014-09-30 22:20:53 +10:00
package.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
pkghash.c Use MALLOC throughtout libalpm 2014-03-08 16:58:30 +10:00
pkghash.h Update copyright years for 2014 2014-01-06 14:38:50 +10:00
rawstr.c Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
remove.c move _alpm_lstat into util-common 2014-08-03 18:46:32 +10:00
remove.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
sha2.c Use 32-bit wide integer type in PolarSSL code 2012-01-07 11:27:41 -06:00
sha2.h Add sha2 (sha256) routines from PolarSSL 2011-08-15 07:07:13 -05:00
signing.c _alpm_key_in_keychain: cache known keys 2014-10-01 09:12:54 +10:00
signing.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
sync.c check_keyring: skip keys known to be missing 2014-10-01 09:10:08 +10:00
sync.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
trans.c wrap fgets to retry on EINTR 2014-09-23 21:43:16 +10:00
trans.h Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00
util-common.c Split common utility functions for libalpm and pacman 2013-01-04 21:49:37 +10:00
util-common.h Split common utility functions for libalpm and pacman 2013-01-04 21:49:37 +10:00
util.c wrap fgets to retry on EINTR 2014-09-23 21:43:16 +10:00
util.h move _alpm_lstat into util-common 2014-08-03 18:46:32 +10:00
version.c Remove ts and sw from vim modeline when noet is set 2014-01-28 20:19:25 +10:00