[pacman-dev] [GIT] The official pacman repository branch, master, updated. v3.3.3-97-g8a8dfc9
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "The official pacman repository". The branch, master has been updated via 8a8dfc9d55c6045d59bed6cde4ae6e2307b335ea (commit) via d2dbb04a9af7a18da217fb21b9152626c43461da (commit) via be266b43647ef57632d7bcfd07a4441f737b5aed (commit) from 120cd312e49b9fbb844dd36c71fe1f2e2910b707 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 8a8dfc9d55c6045d59bed6cde4ae6e2307b335ea Author: Dan McGee <dan@archlinux.org> Date: Sun Nov 15 20:21:50 2009 -0600 HACKING: add some notes about valgrind/gdb usage Signed-off-by: Dan McGee <dan@archlinux.org> commit d2dbb04a9af7a18da217fb21b9152626c43461da Author: Dan McGee <dan@archlinux.org> Date: Wed Nov 11 23:39:26 2009 -0600 download: major refactor to address lingering issues Sorry for this being such a huge patch, but I believe it is necessary for quite a few reasons which I will attempt to explain herein. I've been mulling this over for a while, but wasn't super happy with making the download interface more complex. Instead, if we carefully order things in the internal download code, we can actually make the interface simpler. 1. FS#15657 - This involves `name.db.tar.gz.part` files being left around the filesystem, and then causing all sorts of issues when someone attempts to rerun the operation they canceled. We need to ensure that if we resume a download, we are resuming it on exactly the same file; if we cannot be almost postive of that then we need to start over. 2. http://www.mail-archive.com/pacman-dev@archlinux.org/msg03536.html - Here we have a lighttpd bug to ruin the day. If we send both a Range: header and If-Modified-Since: header across the wire in a GET request, lighttpd doesn't do what we want in several cases. If the file hadn't been modified, it returns a '304 Not Modified' instead of a '206 Partial Content'. We need to do a stat (e.g. HEAD in HTTP terms) operation here, and the proceed accordingly based off the values we get back from it. 3. The mtime stuff was rather ugly, and relied on the called function to write back to a passed in reference, which isn't the greatest. Instead, use the power of the filesystem to contain this info. Every file downloaded internally is now carefully timestamped with the remote file time. This should allow the resume logic to work. In order to guarantee this, we need to implement a signal handler that catches interrupts, notifies the running code, and causes it to set the mtimes on the file. It then rethrows the signal so the pacman signal handler (or any frontend) works as expected. 4. We did a lot of funky stuff in trying to track the DB last modified time. It is a lot easier to just keep the downloaded DB file around and track the time on that rather than in a funky dot file. It also kills a lot of code. 5. For GPG verification of the databases down the road, we are going to need the DB file around for at least a short bit of time anyway, so this gets us closer to that. Signed-off-by: Dan McGee <dan@archlinux.org> [Xav: fixed printf with off_t] Signed-off-by: Xavier Chantry <shiningxc@gmail.com> commit be266b43647ef57632d7bcfd07a4441f737b5aed Author: Laszlo Papp <djszapi2@gmail.com> Date: Fri Nov 13 00:59:34 2009 +0100 Refactor do/while cycle and multiple while cycles * It makes the code clearer to read/understand * Cppcheck tool doesn't show this anymore: [./util.c:215]: (error) Resource leak: fd [Dan: don't change the coding style] Signed-off-by: Dan McGee <dan@archlinux.org> ----------------------------------------------------------------------- Summary of changes: HACKING | 13 ++++ lib/libalpm/alpm.h | 8 +-- lib/libalpm/be_files.c | 96 ++------------------------- lib/libalpm/dload.c | 177 +++++++++++++++++++++++++++++++++--------------- lib/libalpm/dload.h | 4 +- lib/libalpm/trans.c | 5 +- lib/libalpm/util.c | 11 ++- src/pacman/pacman.c | 15 ++++- 8 files changed, 168 insertions(+), 161 deletions(-) hooks/post-receive -- The official pacman repository
participants (1)
-
dan@archlinux.org