[PATCH 3/3] lorax: check for output directory early and quit

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: "Brian C. Lane" <bcl@xxxxxxxxxx>

---
 src/sbin/lorax |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/src/sbin/lorax b/src/sbin/lorax
index 06bc019..8d73ac6 100755
--- a/src/sbin/lorax
+++ b/src/sbin/lorax
@@ -93,6 +93,9 @@ def main(args):
             or not opts.source or not outputdir:
         parser.error("missing one or more required arguments")
 
+    if os.path.exists(outputdir):
+        parser.error("output directory should not exist.")
+
     # create the temporary directory for lorax
     tempdir = tempfile.mkdtemp(prefix="lorax.", dir=tempfile.gettempdir())
 
-- 
1.7.6.4

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux