diff options
author | Charles-François Natali <neologix@free.fr> | 2012-06-23 08:17:05 (GMT) |
---|---|---|
committer | Charles-François Natali <neologix@free.fr> | 2012-06-23 08:17:05 (GMT) |
commit | 9b0c006eb0fa1c8b2514067fdcf6350a45722417 (patch) | |
tree | 7953bc3d20b39f8eeebb0e87ff5ba0dd8ab8c91e /Modules | |
parent | a07548e97bd819884ed1ddcfedb0fcbcbfdc58fe (diff) | |
download | cpython-9b0c006eb0fa1c8b2514067fdcf6350a45722417.zip cpython-9b0c006eb0fa1c8b2514067fdcf6350a45722417.tar.gz cpython-9b0c006eb0fa1c8b2514067fdcf6350a45722417.tar.bz2 |
Remove useless test (flowinfo is unsigned).
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/socketmodule.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/socketmodule.c b/Modules/socketmodule.c index 320227f..338622d 100644 --- a/Modules/socketmodule.c +++ b/Modules/socketmodule.c @@ -1347,7 +1347,7 @@ getsockaddrarg(PySocketSockObject *s, PyObject *args, "getsockaddrarg: port must be 0-65535."); return 0; } - if (flowinfo < 0 || flowinfo > 0xfffff) { + if (flowinfo > 0xfffff) { PyErr_SetString( PyExc_OverflowError, "getsockaddrarg: flowinfo must be 0-1048575."); @@ -4129,7 +4129,7 @@ socket_getnameinfo(PyObject *self, PyObject *args) if (!PyArg_ParseTuple(sa, "si|II", &hostp, &port, &flowinfo, &scope_id)) return NULL; - if (flowinfo < 0 || flowinfo > 0xfffff) { + if (flowinfo > 0xfffff) { PyErr_SetString(PyExc_OverflowError, "getsockaddrarg: flowinfo must be 0-1048575."); return NULL; |