diff Modules/selectmodule.c @ 18754:3cd03a64c338 legacy-trunk

Make more warnings go away on the SGI compiler. This is part of SF patch #424992.
author Fred Drake <fdrake@acm.org>
date Thu, 19 Jul 2001 21:29:49 +0000
parents b9d47d083d2c
children 6cb9f538dce4
line wrap: on
line diff
--- a/Modules/selectmodule.c	Thu Jul 19 21:16:41 2001 +0000
+++ b/Modules/selectmodule.c	Thu Jul 19 21:29:49 2001 +0000
@@ -332,7 +332,7 @@
 static int
 update_ufd_array(pollObject *self)
 {
-	int i, j, pos;
+	int i, pos;
 	PyObject *key, *value;
 
 	self->ufd_len = PyDict_Size(self->dict);
@@ -343,9 +343,9 @@
 	}
 
 	i = pos = 0;
-	while ((j = PyDict_Next(self->dict, &pos, &key, &value))) {
+	while (PyDict_Next(self->dict, &pos, &key, &value)) {
 		self->ufds[i].fd = PyInt_AsLong(key);
-		self->ufds[i].events = PyInt_AsLong(value);
+		self->ufds[i].events = (short)PyInt_AsLong(value);
 		i++;
 	}
 	self->ufd_uptodate = 1;