mjschultz / py-radix

Python radix tree implementation for IPv4 and IPv6 prefix matching.
Other
121 stars 37 forks source link

Added Windows support with win_inet_pton #38

Open bgianpetro opened 6 years ago

bgianpetro commented 6 years ago

I found this in the 'Issues' and decided to provide a fix. I know it's not preferable to have the external dependency on 'win_inet_pton', but that was the only way I could get it working. If this isn't ideal, I can just a blurb to the README for Windows users to note that an install and conditional include of 'win_inet_pton" is required.

coveralls commented 6 years ago

Coverage Status

Coverage decreased (-0.2%) to 90.175% when pulling 873e929fbbc6adcc17644c3a939edcf93d6faa4b on bgianpetro:master into 52d70b050a1dcbf3a7849aa51b2420883e31539e on mjschultz:master.

mjschultz commented 6 years ago

No, I think this is fine. But I would like a blurb in the README stating that Windows does depend on this external library. I think something like (in the installation section):

Windows
^^^^^^^
Windows support depends on a third-party library--`win-inet-pton`--to provide `inet_pton` and `inet_ntop` wrappers for the socket library. It is automatically included for installations on the Windows platform.
bgianpetro commented 6 years ago

Ok, I added that into the README verbatim (it looked good to me!)