From: Billy G. A. <bal...@us...> - 2001-09-17 03:44:56
|
Update of /cvsroot/pypgsql/pypgsql In directory usw-pr-cvs1:/tmp/cvs-serv9769 Modified Files: pgversion.c Log Message: 16SEP2001 bga Fixed a problem that occurred with Python 2.2, which requires that a -1 be returned from the comparison function before it will honor any raised exceptions (this behaviour is changed from Python 2.1 and 2.0). Index: pgversion.c =================================================================== RCS file: /cvsroot/pypgsql/pypgsql/pgversion.c,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** pgversion.c 2001/09/16 17:53:27 1.9 --- pgversion.c 2001/09/17 03:44:53 1.10 *************** *** 32,35 **** --- 32,38 ---- | Date Ini Description | | --------- --- ------------------------------------------------------- | + | 16SEP2001 bga Fixed a problem that occurred with Python 2.2, which | + | requires a -1 to be returned from the comparison func- | + | tion before it honors any exception. | | 15SEP2001 bga Fixed problem where a variable in PgVersion_New() could | | be used before it was initialized. | *************** *** 487,490 **** --- 490,494 ---- t->version = Py_None; Py_XINCREF(t->version); t->minor = Py_None; Py_XINCREF(t->minor); + return (-1); } return (left < right) ? -1 : (left > right) ? 1 : 0; |