mirror of
https://github.com/python/cpython.git
synced 2025-01-27 11:33:55 +08:00
Merged revisions 81024 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r81024 | mark.dickinson | 2010-05-09 13:16:29 +0100 (Sun, 09 May 2010) | 1 line Fix test_urllib2 failure on OS X. ........
This commit is contained in:
parent
9c39bc7265
commit
b7d943625c
@ -2163,7 +2163,7 @@ if sys.platform == 'darwin':
|
||||
|
||||
def ip2num(ipAddr):
|
||||
parts = ipAddr.split('.')
|
||||
parts = map(int, parts)
|
||||
parts = list(map(int, parts))
|
||||
if len(parts) != 4:
|
||||
parts = (parts + [0, 0, 0, 0])[:4]
|
||||
return (parts[0] << 24) | (parts[1] << 16) | (parts[2] << 8) | parts[3]
|
||||
|
Loading…
Reference in New Issue
Block a user