mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
Use INADDR_BROADCAST instead of hard-coded value (it's part of POSIX and
already appears without #ifdef a couple lines above).
This commit is contained in:
parent
fcfb324e81
commit
24aa041731
1 changed files with 1 additions and 1 deletions
|
@ -4940,7 +4940,7 @@ socket_inet_aton(PyObject *self, PyObject *args)
|
|||
/* special-case this address as inet_addr might return INADDR_NONE
|
||||
* for this */
|
||||
if (strcmp(ip_addr, "255.255.255.255") == 0) {
|
||||
packed_addr = 0xFFFFFFFF;
|
||||
packed_addr = INADDR_BROADCAST;
|
||||
} else {
|
||||
|
||||
packed_addr = inet_addr(ip_addr);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue