Skip to content

Commit

Permalink
urllib2 appends .local to base hostnames in the cookie files, which b…
Browse files Browse the repository at this point in the history
…reaks the lookup.
  • Loading branch information
coderanger committed Aug 19, 2010
1 parent 9996339 commit 2b897a3
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions rbtools/postreview.py
Expand Up @@ -366,6 +366,10 @@ def has_valid_cookie(self):
# Cookie files don't store port numbers, unfortunately, so
# get rid of the port number if it's present.
host = host.split(":")[0]

# Cookie files also append .local to bare hostnames
if '.' not in host:
host += '.local'

debug("Looking for '%s %s' cookie in %s" % \
(host, path, self.cookie_file))
Expand Down

0 comments on commit 2b897a3

Please sign in to comment.