lib/repo: Separate min-free-space-* calculation from transaction codepath
Earlier, the actual reserved space (in blocks) were calculated inside the transaction codepath ostree_repo_prepare_transaction(). However, while reworking on ostree_repo_get_min_free_space_bytes() API, it was realized that this calculation can be done independently from the transaction's codepaths, hence enabling the usage for ostree_repo_get_min_free_space_bytes() API irrespective of whether there is an ongoing transaction or not. https://github.com/ostreedev/ostree/issues/1720 Closes: #1722 Approved by: pwithnall
This commit is contained in:
1 parent
fc84fb402c
commit
a0937b6cf0
3 files changed
+50
-35
No files matched your search
@@ -128,7 +128,9 @@ _OSTREE_PUBLIC
|
||||
OstreeRepoMode ostree_repo_get_mode (OstreeRepo *self);
|
||||
|
||||
_OSTREE_PUBLIC
|
||||
guint64 ostree_repo_get_min_free_space_bytes (OstreeRepo *self);
|
||||
gboolean ostree_repo_get_min_free_space_bytes (OstreeRepo *self,
|
||||
guint64 *out_reserved_bytes,
|
||||
GError **error);
|
||||
_OSTREE_PUBLIC
|
||||
GKeyFile * ostree_repo_get_config (OstreeRepo *self);
|
||||
|
||||
|
||||
Reference in new issue
Block a user