Ensure we have a root partition when checking space
On 17/03/11 20:16, Dan McGee wrote:
Partially addresses the "why doesn't CheckSpace work in a chroot" issue.
We can't make it work, but we can at least detect when it won't work by
the lack of a root partition to bucket the stragglers into. Check the
last item in the mountpoint list to ensure it is our root device, and if
not, bail out with an error.
Signed-off-by: Dan McGee<firstname.lastname@example.org>
For maint? Allan, Eric, enjoy, I think this should help address things, but
testing it out in a chroot would be much appreciated.
This looks good. I will do some testing with it later, but it seems
fine for a maint release.
But... lets look for an extreme edge case! Using "pacman -r <dir>"
does not necessarily need the / partition to be found, just the one
containing <dir>. I'm not sure such a set-up is possible, so I am
happy ignoring it until someone actually reports it...
As an asdie, with this check, we should never encounter the error when a
file can not be matched to a mountpoint. So that string update should
never be seen. :P