OstreeMutableTree: add _remove method
There is no API method to remove a file or subdirectory from a MutableTree besides directly manipulating the GHashTable returned by _get_files or _get_subdirs. This isn't possible from an introspection binding that transforms the returned GHashTable, and may also leave the tree checksum in an invalid state. Introduce a new method so that removing files or subdirectories is safe, and possible from bindings. Closes: #1724 Approved by: jlebon
This commit is contained in:
1 parent
6b37fe8310
commit
b32c9e0df9
4 files changed
+53
No files matched your search
@@ -77,6 +77,12 @@ gboolean ostree_mutable_tree_replace_file (OstreeMutableTree *self,
|
||||
const char *checksum,
|
||||
GError **error);
|
||||
|
||||
_OSTREE_PUBLIC
|
||||
gboolean ostree_mutable_tree_remove (OstreeMutableTree *self,
|
||||
const char *name,
|
||||
gboolean allow_noent,
|
||||
GError **error);
|
||||
|
||||
_OSTREE_PUBLIC
|
||||
gboolean ostree_mutable_tree_ensure_dir (OstreeMutableTree *self,
|
||||
const char *name,
|
||||
|
||||
Reference in new issue
Block a user