Message347339
> inet_pton() requires an address family. Should we iterate on all supported address families until one works?
No, that is not necessary. inet_aton() only accepts IPv4 addresses. Therefore an emulation with inet_pton() would look like this:
>>> import functools, socket
>>> inet_aton = functools.partial(socket.inet_pton, socket.AF_INET)
>>> inet_aton('127.0.0.1')
b'\x7f\x00\x00\x01'
> inet_pton() doesn't accept IPv4 "short format" like "127"
Yes, that might be a problem. |
|
Date |
User |
Action |
Args |
2019-07-05 12:52:09 | christian.heimes | set | recipients:
+ christian.heimes, vstinner, aldwinaldwin, Dominik Czarnota |
2019-07-05 12:52:09 | christian.heimes | set | messageid: <1562331129.58.0.859457166787.issue37495@roundup.psfhosted.org> |
2019-07-05 12:52:09 | christian.heimes | link | issue37495 messages |
2019-07-05 12:52:09 | christian.heimes | create | |
|