summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoger Leigh <rleigh@debian.org>2010-07-10 23:33:13 +0100
committerRoger Leigh <rleigh@debian.org>2010-07-11 21:00:27 +0100
commit8b905aa41c3573c857143f629326a2553139cf11 (patch)
tree06f41d9d0069dd59c2077d6f87bddd2f667b696e
parenta63d70e5cfdf9571aa1ab996f71505a72bf04c0d (diff)
downloadschroot-8b905aa41c3573c857143f629326a2553139cf11.tar.gz
dchroot: Use new chroot_config interface
-rw-r--r--bin/dchroot-dsa/dchroot-dsa-chroot-config.cc14
-rw-r--r--bin/dchroot-dsa/dchroot-dsa-chroot-config.h8
-rw-r--r--bin/dchroot/dchroot-chroot-config.cc14
-rw-r--r--bin/dchroot/dchroot-chroot-config.h8
4 files changed, 20 insertions, 24 deletions
diff --git a/bin/dchroot-dsa/dchroot-dsa-chroot-config.cc b/bin/dchroot-dsa/dchroot-dsa-chroot-config.cc
index 2d9997ee..2b623d3b 100644
--- a/bin/dchroot-dsa/dchroot-dsa-chroot-config.cc
+++ b/bin/dchroot-dsa/dchroot-dsa-chroot-config.cc
@@ -42,9 +42,9 @@ chroot_config::chroot_config ():
{
}
-chroot_config::chroot_config (std::string const& file,
- bool active):
- sbuild::chroot_config(file, active)
+chroot_config::chroot_config (std::string const& chroot_namespace,
+ std::string const& file):
+ sbuild::chroot_config(chroot_namespace, file)
{
}
@@ -53,11 +53,9 @@ chroot_config::~chroot_config ()
}
void
-chroot_config::parse_data (std::istream& stream,
- bool active)
+chroot_config::parse_data (std::string const& chroot_namespace,
+ std::istream& stream)
{
- active = false; // dchroot does not support sessions.
-
size_t linecount = 0;
std::string line;
std::string chroot_name;
@@ -128,5 +126,5 @@ chroot_config::parse_data (std::istream& stream,
}
}
- load_keyfile(kconfig, active);
+ load_keyfile(chroot_namespace, kconfig);
}
diff --git a/bin/dchroot-dsa/dchroot-dsa-chroot-config.h b/bin/dchroot-dsa/dchroot-dsa-chroot-config.h
index a1d10659..166b5d8f 100644
--- a/bin/dchroot-dsa/dchroot-dsa-chroot-config.h
+++ b/bin/dchroot-dsa/dchroot-dsa-chroot-config.h
@@ -45,16 +45,16 @@ namespace dchroot_dsa
* @param active true if the chroots in the configuration file are
* active sessions, otherwise false.
*/
- chroot_config (std::string const& file,
- bool active);
+ chroot_config (std::string const& chroot_namespace,
+ std::string const& file);
/// The destructor.
virtual ~chroot_config ();
private:
virtual void
- parse_data (std::istream& stream,
- bool active);
+ parse_data (std::string const& chroot_namespace,
+ std::istream& stream);
};
}
diff --git a/bin/dchroot/dchroot-chroot-config.cc b/bin/dchroot/dchroot-chroot-config.cc
index 5d06bc92..f37d97b0 100644
--- a/bin/dchroot/dchroot-chroot-config.cc
+++ b/bin/dchroot/dchroot-chroot-config.cc
@@ -42,9 +42,9 @@ chroot_config::chroot_config ():
{
}
-chroot_config::chroot_config (std::string const& file,
- bool active):
- sbuild::chroot_config(file, active)
+chroot_config::chroot_config (std::string const& chroot_namespace,
+ std::string const& file):
+ sbuild::chroot_config(chroot_namespace, file)
{
}
@@ -53,11 +53,9 @@ chroot_config::~chroot_config ()
}
void
-chroot_config::parse_data (std::istream& stream,
- bool active)
+chroot_config::parse_data (std::string const& chroot_namespace,
+ std::istream& stream)
{
- active = false; // dchroot does not support sessions.
-
size_t linecount = 0;
std::string line;
std::string chroot_name;
@@ -151,5 +149,5 @@ chroot_config::parse_data (std::istream& stream,
}
}
- load_keyfile(kconfig, active);
+ load_keyfile(chroot_namespace, kconfig);
}
diff --git a/bin/dchroot/dchroot-chroot-config.h b/bin/dchroot/dchroot-chroot-config.h
index 1ee47790..1d58c182 100644
--- a/bin/dchroot/dchroot-chroot-config.h
+++ b/bin/dchroot/dchroot-chroot-config.h
@@ -45,16 +45,16 @@ namespace dchroot
* @param active true if the chroots in the configuration file are
* active sessions, otherwise false.
*/
- chroot_config (std::string const& file,
- bool active);
+ chroot_config (std::string const& chroot_namespace,
+ std::string const& file);
/// The destructor.
virtual ~chroot_config ();
private:
virtual void
- parse_data (std::istream& stream,
- bool active);
+ parse_data (std::string const& chroot_namespace,
+ std::istream& stream);
};
}