2010-10-20 15:23:06 +02:00
|
|
|
Index: InitScriptCheck.py
|
|
|
|
===================================================================
|
|
|
|
--- InitScriptCheck.py.orig
|
2008-04-17 04:52:37 +02:00
|
|
|
+++ InitScriptCheck.py
|
2014-02-21 15:54:14 +01:00
|
|
|
@@ -18,7 +18,7 @@ from Filter import addDetails, printErro
|
2010-10-14 14:32:03 +02:00
|
|
|
import AbstractCheck
|
|
|
|
import Config
|
2008-04-17 04:52:37 +02:00
|
|
|
import Pkg
|
2010-10-14 14:32:03 +02:00
|
|
|
-
|
2008-04-17 04:52:37 +02:00
|
|
|
+import stat
|
|
|
|
|
2010-10-14 14:32:03 +02:00
|
|
|
chkconfig_content_regex = re.compile('^\s*#\s*chkconfig:\s*([-0-9]+)\s+[-0-9]+\s+[-0-9]+')
|
|
|
|
subsys_regex = re.compile('/var/lock/subsys/([^/"\'\n\s;&|]+)', re.MULTILINE)
|
2014-02-21 15:54:14 +01:00
|
|
|
@@ -64,6 +64,9 @@ class InitScriptCheck(AbstractCheck.Abst
|
2010-10-20 15:23:06 +02:00
|
|
|
not fname.startswith('/etc/rc.d/init.d/'):
|
2010-10-14 14:32:03 +02:00
|
|
|
continue
|
|
|
|
|
2010-10-20 15:23:06 +02:00
|
|
|
+ if not stat.S_ISREG(pkgfile.mode):
|
|
|
|
+ continue
|
|
|
|
+
|
2010-10-14 14:32:03 +02:00
|
|
|
basename = os.path.basename(fname)
|
2010-10-20 15:23:06 +02:00
|
|
|
initscript_list.append(basename)
|
2014-02-21 15:54:14 +01:00
|
|
|
if pkgfile.mode & int("500", 8) != int("500", 8):
|