style and typos
authorJF Ding <jian-feng.ding@intel.com>
Thu, 17 Nov 2011 10:59:13 +0000 (18:59 +0800)
committerJF Ding <jian-feng.ding@intel.com>
Thu, 17 Nov 2011 10:59:13 +0000 (18:59 +0800)
mic/utils/misc.py

index c606bfe..785b136 100644 (file)
@@ -63,16 +63,19 @@ def save_ksconf_file(ksconf, release="latest", arch="ia32"):
     return ksconf
 
 def check_meego_chroot(rootdir):
-    if not os.path.exists(rootdir + "/etc/moblin-release") \
-        and not os.path.exists(rootdir + "/etc/meego-release"):
-        raise CreatorError("Directory %s is not a MeeGo/Tizen chroot env" \
+    if not os.path.exists(rootdir + "/etc/moblin-release") and \
+       not os.path.exists(rootdir + "/etc/meego-release"):
+        raise CreatorError("Directory %s is not a MeeGo/Tizen chroot env"\
                            % rootdir)
-    if not os.path.exists(rootdir + "/etc/inittab") \
-        or not os.path.exists(rootdir + "/etc/rc.sysinit"):
-        raise CreatorError("Lack of init scripts under %s: /etc/inittab, " \
+
+    if not os.path.exists(rootdir + "/etc/inittab") or \
+       not os.path.exists(rootdir + "/etc/rc.sysinit"):
+        raise CreatorError("Lack of init scripts under %s: /etc/inittab, "\
                            "/etc/rc.sysinit" % rootdir)
+
     if not glob.glob(rootdir + "/boot/vmlinuz-*"):
         raise CreatorError("Failed to find kernel module under %s" % rootdir)
+
     return
 
 def get_image_type(path):
@@ -85,7 +88,7 @@ def get_image_type(path):
             return None
 
     if os.path.isdir(path):
-        check_meego_chroot(path):
+        check_meego_chroot(path)
         return "fs"
 
     maptab = {