From b9819b8f173d6e0cc2ac6c2e189691e1854ef2a8 Mon Sep 17 00:00:00 2001 From: Clark Williams Date: Wed, 8 Jul 2009 11:43:42 -0500 Subject: added code to raise exception when --shell specified for uninitialized chroot. BZ# 506288 Signed-off-by: Clark Williams --- py/mock.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/py/mock.py b/py/mock.py index c5f057b..a09e6d8 100755 --- a/py/mock.py +++ b/py/mock.py @@ -566,6 +566,8 @@ def main(ret): elif options.mode == 'shell': chroot.tryLockBuildRoot() + if not os.path.exists(chroot.makeChrootPath()): + raise RuntimeError, "chroot %s not initialized!" % chroot.makeChrootPath() try: chroot._mountall() cmd = ' '.join(args) -- cgit