[buildd-tools-devel] [PATCH 08/11] [chroot_union] Read union type before source keys
Jan-Marek Glogowski
glogow at fbihome.de
Thu Jul 30 19:10:57 UTC 2009
As the source interface depends on the configured union read
the union type before reading the source keyfile values.
---
sbuild/sbuild-chroot-union.cc | 14 ++++++++++++--
1 files changed, 12 insertions(+), 2 deletions(-)
diff --git a/sbuild/sbuild-chroot-union.cc b/sbuild/sbuild-chroot-union.cc
index 9968ae7..e2ed197 100644
--- a/sbuild/sbuild-chroot-union.cc
+++ b/sbuild/sbuild-chroot-union.cc
@@ -220,11 +220,16 @@ chroot_union::get_keyfile (keyfile& keyfile) const
assert(base != 0);
chroot_session::get_keyfile(keyfile);
- chroot_source::get_keyfile(keyfile);
+ /**
+ * As the source interface depends on the configured union read union type
+ * before reading the source keyfile values.
+ */
keyfile::set_object_value(*this, &chroot_union::get_union_type,
keyfile, base->get_keyfile_name(), "union-type");
+ chroot_source::get_keyfile(keyfile);
+
if (get_union_configured())
{
keyfile::set_object_value(*this,
@@ -253,13 +258,18 @@ chroot_union::set_keyfile (keyfile const& keyfile,
assert(base != 0);
chroot_session::set_keyfile(keyfile, used_keys);
- chroot_source::set_keyfile(keyfile, used_keys);
+ /**
+ * As the source interface depends on the configured union read union type
+ * before reading the source keyfile values.
+ */
keyfile::get_object_value(*this, &chroot_union::set_union_type,
keyfile, base->get_keyfile_name(), "union-type",
keyfile::PRIORITY_OPTIONAL);
used_keys.push_back("union-type");
+ chroot_source::set_keyfile(keyfile, used_keys);
+
keyfile::get_object_value(*this,
&chroot_union::set_union_mount_options,
keyfile, base->get_keyfile_name(), "union-mount-options",
--
1.6.3.2
More information about the Buildd-tools-devel
mailing list