2008-04-17 04:52:37 +02:00
|
|
|
--- InitScriptCheck.py
|
|
|
|
+++ InitScriptCheck.py
|
2010-10-14 14:32:03 +02:00
|
|
|
@@ -18,7 +18,7 @@
|
|
|
|
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)
|
|
|
|
@@ -50,7 +50,8 @@
|
|
|
|
for fname, pkgfile in pkg.files().items():
|
2008-04-17 04:52:37 +02:00
|
|
|
|
2010-10-14 14:32:03 +02:00
|
|
|
if not fname.startswith('/etc/init.d/') and \
|
|
|
|
- not fname.startswith('/etc/rc.d/init.d/'):
|
|
|
|
+ not fname.startswith('/etc/rc.d/init.d/') and \
|
|
|
|
+ stat.S_ISREG(pkgfile.mode):
|
|
|
|
continue
|
|
|
|
|
|
|
|
basename = os.path.basename(fname)
|