Permalink
Browse files

No need to use a regexp for searching. Be a bit more specific in

what we search for.
  • Loading branch information...
1 parent 44d1707 commit fbc49b60ed8f7e309762dfbf7f2962fc6aea6014 @noj noj committed Sep 30, 2010
Showing with 1 addition and 3 deletions.
  1. +1 −3 master/contrib/windows/buildbot_service.py
@@ -66,7 +66,6 @@
import sys
import os
import threading
-import re
import pywintypes
import winerror
@@ -525,10 +524,9 @@ def DetermineRunner(bbdir):
tacfile = os.path.join(bbdir, 'buildbot.tac')
if os.path.exists(tacfile):
- rexp = re.compile("BuildSlave")
with open(tacfile, 'r') as f:
contents = f.read()
- if rexp.search(contents):
+ if 'import BuildSlave' in contents:
return buildslave.scripts.runner.run
except ImportError:

0 comments on commit fbc49b6

Please sign in to comment.