Mercurial > cpython-lru_cache-weakref
diff Modules/socketmodule.c @ 77611:e5478b6b93b5 2.7
Remove useless test (flowinfo is unsigned).
| author | Charles-François Natali <neologix@free.fr> |
|---|---|
| date | Sat, 23 Jun 2012 10:06:56 +0200 |
| parents | 0c10061df711 |
| children | b7d4a13c736e |
line wrap: on
line diff
--- a/Modules/socketmodule.c Fri Jun 22 10:38:48 2012 -0400 +++ b/Modules/socketmodule.c Sat Jun 23 10:06:56 2012 +0200 @@ -1310,7 +1310,7 @@ "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."); @@ -4181,7 +4181,7 @@ 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;
