[Python-checkins] CVS: python/dist/src/Objects floatobject.c,2.67,2.68
Barry Warsaw
python-dev@python.org
Thu, 17 Aug 2000 22:00:05 -0700
Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv26829
Modified Files:
floatobject.c
Log Message:
PyFloat_FromString(): Move s_buffer[] up to the top-level function
scope. Previously, s_buffer[] was defined inside the
PyUnicode_Check() scope, but referred to in the outer scope via
assignment to s. This quiets an Insure portability warning.
Index: floatobject.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Objects/floatobject.c,v
retrieving revision 2.67
retrieving revision 2.68
diff -C2 -r2.67 -r2.68
*** floatobject.c 2000/08/15 03:34:48 2.67
--- floatobject.c 2000/08/18 05:00:03 2.68
***************
*** 134,137 ****
--- 134,138 ----
double x;
char buffer[256]; /* For errors */
+ char s_buffer[256];
int len;
***************
*** 141,146 ****
}
else if (PyUnicode_Check(v)) {
- char s_buffer[256];
-
if (PyUnicode_GET_SIZE(v) >= sizeof(s_buffer)) {
PyErr_SetString(PyExc_ValueError,
--- 142,145 ----