diff options
author | Charles-François Natali <neologix@free.fr> | 2012-06-23 08:26:54 (GMT) |
---|---|---|
committer | Charles-François Natali <neologix@free.fr> | 2012-06-23 08:26:54 (GMT) |
commit | f8f5237b2f0579631cf53ddf1e76fb1e4c31dc52 (patch) | |
tree | a14fa76ac7488066170aa2dddc7ed30817b6cbf2 /Modules/socketmodule.c | |
parent | dc00f1eba01fb51f655644c2900adb3fca3de1dd (diff) | |
parent | 9b0c006eb0fa1c8b2514067fdcf6350a45722417 (diff) | |
download | cpython-f8f5237b2f0579631cf53ddf1e76fb1e4c31dc52.zip cpython-f8f5237b2f0579631cf53ddf1e76fb1e4c31dc52.tar.gz cpython-f8f5237b2f0579631cf53ddf1e76fb1e4c31dc52.tar.bz2 |
Remove useless test (flowinfo is unsigned).
Diffstat (limited to 'Modules/socketmodule.c')
-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 936e930..804e09e 100644 --- a/Modules/socketmodule.c +++ b/Modules/socketmodule.c @@ -1437,7 +1437,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."); @@ -5119,7 +5119,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; |