Permalink
Browse files

Bug 708798 - buildbot-wrangler.py shouldn't fail when twistd.log is a…

…bsent. r=catlee
  • Loading branch information...
1 parent 7a4d4aa commit ca71911338973071f98188442d63c0a0323a1e47 Edmund Wong committed Oct 30, 2012
Showing with 8 additions and 0 deletions.
  1. +8 −0 buildfarm/maintenance/buildbot-wrangler.py
@@ -21,6 +21,14 @@ def __init__(self, fname):
self.started = False
+ if os.path.exists(fname):
+ os.utime(fname, None)
+ else:
+ try:
+ open(fname, 'w').close()
+ except:
+ print "Could not create %s." % fname
+ sys.exit(1)
self.fp = open(fname)
self.fp.seek(0, 2) # SEEK_END
self.current_inode = os.fstat(self.fp.fileno()).st_ino

0 comments on commit ca71911

Please sign in to comment.