Adjust the EbuildNestedDie pattern so that it only matches when ( is surrounded v2.2_rc18
authorZac Medico <zmedico@gentoo.org>
Sat, 20 Dec 2008 20:22:39 +0000 (20:22 -0000)
committerZac Medico <zmedico@gentoo.org>
Sat, 20 Dec 2008 20:22:39 +0000 (20:22 -0000)
by whitespace. This filters out false positives triggered by sed expressions in
net-analyzer/amap-5.2-r1 and media-libs/libsndfile-1.0.17-r1. Thanks to Diego
Pettenò <flameeyes@g.o> for reporting.

svn path=/main/trunk/; revision=12265

pym/repoman/checks.py

index 6f2c076c32907785a52a4b95bf62fe3390f5928c..7565039f274af031be89299a7336ae4e8034e35a 100644 (file)
@@ -177,7 +177,7 @@ class EbuildNestedDie(LineCheck):
        """Check ebuild for nested die statements (die statements in subshells"""
        
        repoman_check_name = 'ebuild.nesteddie'
-       nesteddie_re = re.compile(r'^[^#]*\([^)]*\bdie\b')
+       nesteddie_re = re.compile(r'^[^#]*\s\(\s[^)]*\bdie\b')
        
        def check(self, num, line):
                if self.nesteddie_re.match(line):