Commit 0368bc44 authored by Fred Drake's avatar Fred Drake

Remove warnings from the SGI compiler.

This is part of SF patch #434992.
parent 78bdb9bc
...@@ -114,9 +114,8 @@ char *PyCursesVersion = "2.1"; ...@@ -114,9 +114,8 @@ char *PyCursesVersion = "2.1";
curses module in other ways. So the code will just specify curses module in other ways. So the code will just specify
explicit prototypes here. */ explicit prototypes here. */
extern int setupterm(char *,int,int *); extern int setupterm(char *,int,int *);
#ifdef sgi #ifdef __sgi
extern char *tigetstr(char *); #include <term.h>
extern char *tparm(char *instring, ...);
#endif #endif
#if defined(sgi) || defined(__sun__) #if defined(sgi) || defined(__sun__)
...@@ -721,7 +720,7 @@ PyCursesWindow_GetCh(PyCursesWindowObject *self, PyObject *args) ...@@ -721,7 +720,7 @@ PyCursesWindow_GetCh(PyCursesWindowObject *self, PyObject *args)
PyErr_SetString(PyExc_TypeError, "getch requires 0 or 2 arguments"); PyErr_SetString(PyExc_TypeError, "getch requires 0 or 2 arguments");
return NULL; return NULL;
} }
return PyInt_FromLong(rtn); return PyInt_FromLong((long)rtn);
} }
static PyObject * static PyObject *
...@@ -1305,7 +1304,6 @@ PyCursesWindow_Scroll(PyCursesWindowObject *self, PyObject *args) ...@@ -1305,7 +1304,6 @@ PyCursesWindow_Scroll(PyCursesWindowObject *self, PyObject *args)
switch(ARG_COUNT(args)) { switch(ARG_COUNT(args)) {
case 0: case 0:
return PyCursesCheckERR(scroll(self->win), "scroll"); return PyCursesCheckERR(scroll(self->win), "scroll");
break;
case 1: case 1:
if (!PyArg_Parse(args, "i;nlines", &nlines)) if (!PyArg_Parse(args, "i;nlines", &nlines))
return NULL; return NULL;
...@@ -1325,7 +1323,6 @@ PyCursesWindow_TouchLine(PyCursesWindowObject *self, PyObject *args) ...@@ -1325,7 +1323,6 @@ PyCursesWindow_TouchLine(PyCursesWindowObject *self, PyObject *args)
if (!PyArg_Parse(args,"(ii);start,count",&st,&cnt)) if (!PyArg_Parse(args,"(ii);start,count",&st,&cnt))
return NULL; return NULL;
return PyCursesCheckERR(touchline(self->win,st,cnt), "touchline"); return PyCursesCheckERR(touchline(self->win,st,cnt), "touchline");
break;
case 3: case 3:
if (!PyArg_Parse(args, "(iii);start,count,val", &st, &cnt, &val)) if (!PyArg_Parse(args, "(iii);start,count,val", &st, &cnt, &val))
return NULL; return NULL;
......
...@@ -1215,7 +1215,7 @@ posix_umask(PyObject *self, PyObject *args) ...@@ -1215,7 +1215,7 @@ posix_umask(PyObject *self, PyObject *args)
int i; int i;
if (!PyArg_ParseTuple(args, "i:umask", &i)) if (!PyArg_ParseTuple(args, "i:umask", &i))
return NULL; return NULL;
i = umask(i); i = (int)umask(i);
if (i < 0) if (i < 0)
return posix_error(); return posix_error();
return PyInt_FromLong((long)i); return PyInt_FromLong((long)i);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment