xbps-install: abort transaction if there's insufficient disk space on rootdir.
The free disk space wasn't computed correctly and xbps-install(8) wasn't handling ENOSPC rval in xbps_transaction_prepare().
This commit is contained in:
@@ -173,7 +173,7 @@ compute_transaction_stats(struct xbps_handle *xhp)
|
||||
return 0;
|
||||
}
|
||||
/* compute free space on disk */
|
||||
rootdir_free_size = svfs.f_bavail * svfs.f_bsize - instsize;
|
||||
rootdir_free_size = svfs.f_bfree * svfs.f_bsize;
|
||||
|
||||
if (!xbps_dictionary_set_uint64(xhp->transd,
|
||||
"disk-free-size", rootdir_free_size))
|
||||
|
||||
Reference in New Issue
Block a user