]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Merged revisions 74051-74052 via svnmerge from
authorAlexandre Vassalotti <alexandre@peadrop.com>
Fri, 17 Jul 2009 08:31:44 +0000 (08:31 +0000)
committerAlexandre Vassalotti <alexandre@peadrop.com>
Fri, 17 Jul 2009 08:31:44 +0000 (08:31 +0000)
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r74051 | alexandre.vassalotti | 2009-07-17 03:54:23 -0400 (Fri, 17 Jul 2009) | 2 lines

  Initialize variables in PyCurses_getsyx() to avoid compiler warnings.
........
  r74052 | alexandre.vassalotti | 2009-07-17 04:09:04 -0400 (Fri, 17 Jul 2009) | 3 lines

  Fix GCC warning about fprintf used without a string literal and
  without format arguments.
........

Modules/_cursesmodule.c
Modules/main.c

index a92cc8e1359267e4ddebb519671ca937133ada9e..c7d377859d2d0e3990981e6c756f0435e5e92c9c 100644 (file)
@@ -1806,7 +1806,8 @@ PyCurses_EraseChar(PyObject *self)
 static PyObject *
 PyCurses_getsyx(PyObject *self)
 {
-  int x,y;
+  int x = 0;
+  int y = 0;
 
   PyCursesInitialised
 
index 8352e6672220e47e52e9d773629f80a114d67aba..22794dafb9b7d6788d2883f1f521a7b2ed0d4e55 100644 (file)
@@ -131,9 +131,9 @@ usage(int exitcode, wchar_t* program)
        if (exitcode)
                fprintf(f, "Try `python -h' for more information.\n");
        else {
-               fprintf(f, usage_1);
-               fprintf(f, usage_2);
-               fprintf(f, usage_3);
+               fputs(usage_1, f);
+               fputs(usage_2, f);
+               fputs(usage_3, f);
                fprintf(f, usage_4, DELIM);
                fprintf(f, usage_5, DELIM, PYTHONHOMEHELP);
        }