Add ostree_commit_get_parent() to get parent from variant
https://bugzilla.gnome.org/show_bug.cgi?id=705973
This commit is contained in:
1 parent
790132a81a
commit
5efb8e86e9
3 files changed
+14
-6
No files matched your search
@@ -1643,3 +1643,13 @@ ostree_validate_structureof_dirmeta (GVariant *dirmeta,
|
||||
out:
|
||||
return ret;
|
||||
}
|
||||
|
||||
gchar *
|
||||
ostree_commit_get_parent (GVariant *commit_variant)
|
||||
{
|
||||
gs_unref_variant GVariant *bytes = NULL;
|
||||
bytes = g_variant_get_child_value (commit_variant, 1);
|
||||
if (g_variant_n_children (bytes) == 0)
|
||||
return NULL;
|
||||
return ostree_checksum_from_bytes_v (bytes);
|
||||
}
|
||||
Reference in new issue
Block a user