]> git.pld-linux.org Git - packages/kernel.git/commitdiff
- print all errors that we can find and then exit with error
authorElan Ruusamäe <glen@pld-linux.org>
Mon, 28 Jan 2008 19:42:40 +0000 (19:42 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    kernel-config.py -> 1.6

kernel-config.py

index e093de74d56d1b41c590346bd069f0f6773360b9..85e2ced008fff5188c07ff3e855ecb329e8ed8e7 100644 (file)
@@ -71,20 +71,27 @@ class odict(UserDict):
 
 dict = odict()
 
+rc = 0
 f = open(kernelconfig, 'r')
 for l in f:
     if l[:6] == 'CONFIG_':
         print "Omit CONFIG_ when specifing symbol name: %s" % l
+        rc = 1
         continue
+
     if re.match('^#', l) or re.match('^\s*$', l):
         continue
+
     if not re.match('^[0-9A-Z]+', l):
         print "Unknown line: %s" % l
-        sys.exit(1)
+        rc = 1
+        continue
+
     c = l.strip().split()
     symbol = c[0]
     if dict.has_key(symbol):
         print "Duplicate symbol %s!" % symbol
+        rc = 1
         continue
 
     par = False
@@ -104,10 +111,14 @@ for l in f:
         dict[symbol] = val
     if not par:
         print "Unknown line: %s" % l
-        sys.exit(1)
+        rc = 1
+        continue
 
 f.close()
 
+if not rc == 0:
+    sys.exit(1)
+
 f = open(inconfig, 'r')
 cfg = f.read()
 f.close()
This page took 0.068424 seconds and 4 git commands to generate.