pacman/lib/libalpm
morganamilo 67e3a7be36
libalpm: fix regression in downloader
Fixes failure to finalize download path if the package file already
exists but the .sig file does not.

This patch also moves .sig.part files which should be done for
completeness although it's probably rare/inconsequential for them to
exist.

Hopefully this is now the right approach now. The logic is as follows:

  Check if dest_name or temp_name exists and try to move whichever
  does.

  If neither exist assume we're just downloading sig files and don't
  error.

  Figure out the .sig base filename.

  Try to move the .sig file if one was needed and if that fails try
  move the .sig.part file.

The patch leaves the logging as is. Maybe we should check if moves fail
for reasons other than non existence and log it properly. Though this is
probably rare and pacman will error out later anyway.

Fixes #256
2025-05-30 14:48:14 +01:00
..
po Update translations for release 2024-07-14 19:11:18 +10:00
.gitignore libalpm: add pkg-config file 2012-04-25 20:02:36 -04:00
add.c Update copyright years 2025-04-02 11:35:34 +10:00
add.h Update copyright years 2025-04-02 11:35:34 +10:00
alpm.c Do not overwrite default download user when option is unset 2025-05-08 21:49:56 +10:00
alpm.h Update copyright years 2025-04-02 11:35:34 +10:00
alpm_list.c Update copyright years 2025-04-02 11:35:34 +10:00
alpm_list.h Update copyright years 2025-04-02 11:35:34 +10:00
backup.c Update copyright years 2025-04-02 11:35:34 +10:00
backup.h Update copyright years 2025-04-02 11:35:34 +10:00
base64.c base64.c: comment out unused variable 2014-01-15 15:54:56 +10:00
base64.h Do not #define _RESERVED_IDENTIFIERS 2016-09-25 18:04:57 +10:00
be_local.c Update copyright years 2025-04-02 11:35:34 +10:00
be_package.c Update copyright years 2025-04-02 11:35:34 +10:00
be_sync.c libalpm: move tempdir cleanup into _alpm_download 2025-05-26 16:13:06 +10:00
conflict.c Update copyright years 2025-04-02 11:35:34 +10:00
conflict.h Update copyright years 2025-04-02 11:35:34 +10:00
db.c Update copyright years 2025-04-02 11:35:34 +10:00
db.h Update copyright years 2025-04-02 11:35:34 +10:00
deps.c Update copyright years 2025-04-02 11:35:34 +10:00
deps.h Update copyright years 2025-04-02 11:35:34 +10:00
diskspace.c Update copyright years 2025-04-02 11:35:34 +10:00
diskspace.h Update copyright years 2025-04-02 11:35:34 +10:00
dload.c libalpm: fix regression in downloader 2025-05-30 14:48:14 +01:00
dload.h Update copyright years 2025-04-02 11:35:34 +10:00
error.c Fix typos 2025-05-04 21:42:34 +10:00
filelist.c Update copyright years 2025-04-02 11:35:34 +10:00
filelist.h Update copyright years 2025-04-02 11:35:34 +10:00
graph.c Update copyright years 2025-04-02 11:35:34 +10:00
graph.h Update copyright years 2025-04-02 11:35:34 +10:00
group.c Update copyright years 2025-04-02 11:35:34 +10:00
group.h Update copyright years 2025-04-02 11:35:34 +10:00
handle.c Update copyright years 2025-04-02 11:35:34 +10:00
handle.h Update copyright years 2025-04-02 11:35:34 +10:00
hook.c Update copyright years 2025-04-02 11:35:34 +10:00
hook.h Update copyright years 2025-04-02 11:35:34 +10:00
libarchive-compat.h Update copyright years 2025-04-02 11:35:34 +10:00
log.c Update copyright years 2025-04-02 11:35:34 +10:00
log.h Update copyright years 2025-04-02 11:35:34 +10:00
meson.build Restrict syscalls for the download process whenever possible 2024-08-02 00:39:45 +00:00
package.c Update copyright years 2025-04-02 11:35:34 +10:00
package.h Update copyright years 2025-04-02 11:35:34 +10:00
pkghash.c Update copyright years 2025-04-02 11:35:34 +10:00
pkghash.h Update copyright years 2025-04-02 11:35:34 +10:00
rawstr.c Remove all modelines from the project 2018-05-14 09:59:15 +10:00
remove.c Update copyright years 2025-04-02 11:35:34 +10:00
remove.h Update copyright years 2025-04-02 11:35:34 +10:00
sandbox.c Update copyright years 2025-04-02 11:35:34 +10:00
sandbox.h Add callbacks for sandboxed operations 2024-04-01 20:52:55 +00:00
sandbox_fs.c Update copyright years 2025-04-02 11:35:34 +10:00
sandbox_fs.h Update copyright years 2025-04-02 11:35:34 +10:00
sandbox_syscalls.c Restrict syscalls for the download process whenever possible 2024-08-02 00:39:45 +00:00
sandbox_syscalls.h Restrict syscalls for the download process whenever possible 2024-08-02 00:39:45 +00:00
signing.c Update copyright years 2025-04-02 11:35:34 +10:00
signing.h Update copyright years 2025-04-02 11:35:34 +10:00
sync.c libalpm: move tempdir cleanup into _alpm_download 2025-05-26 16:13:06 +10:00
sync.h Update copyright years 2025-04-02 11:35:34 +10:00
trans.c Fix typos 2025-05-04 21:42:34 +10:00
trans.h Fix typos 2025-05-04 21:42:34 +10:00
util.c Free memory on failure to create temporary directory 2025-05-06 17:02:35 +10:00
util.h Update copyright years 2025-04-02 11:35:34 +10:00
version.c Update copyright years 2025-04-02 11:35:34 +10:00