Attempt to stop installation when we encounter problems
commit209d0643e5fd38f8add70cfb3651012993d861f1
authorDan McGee <dan@archlinux.org>
Sat, 1 Nov 2008 03:43:55 +0000 (31 22:43 -0500)
committerDan McGee <dan@archlinux.org>
Mon, 13 Dec 2010 03:42:41 +0000 (12 21:42 -0600)
tree860f1b0d5eb37899c6cfa1b87f6e8e2aec320131
parentb276a76dc9e02e1cdc227661ae4ffe97a24d9f4d
Attempt to stop installation when we encounter problems

This should hopefully address some of the concerns raised in FS#11639 with
regards to continuing after filling the disk up.

Add some more checks and passing of error conditions between our functions.
When a libarchive warning is encountered, check if it is due to lack of disk
space and if so upgrade it to an error condition.  A review of other
libarchive warnings suggests that these are less critical and can remain as
informative warning messages at this stage.

Note the presence of errors after extraction of an entire package is complete.
If so, we abort the transaction to be on the safe side and keep damage to a
minimum.

Signed-off-by: Dan McGee <dan@archlinux.org>
[Allan: make ENOSPC warning into an error]
Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
lib/libalpm/add.c