Fixed problem with "fractionary" time zones (Closes: #78).

This commit is contained in:
Federico Di Gregorio 2005-12-11 07:50:27 +00:00
parent 5ea2fa636f
commit 61de8690e9
5 changed files with 11 additions and 25 deletions

View File

@ -1,3 +1,9 @@
2005-12-11 Federico Di Gregorio <fog@initd.org>
* psycopg/typecast.c (typecast_parse_time): cz limit in the while
loop is 6, not 5. This solve the problem with "fractionary" time zones
and fixes #78.
2005-12-06 Federico Di Gregorio <fog@initd.org> 2005-12-06 Federico Di Gregorio <fog@initd.org>
* lib/extras.py: added .callproc() to DictCursor as suggested * lib/extras.py: added .callproc() to DictCursor as suggested

View File

@ -53,7 +53,7 @@ GNU General Public License for more details.
Proprietary licenses Proprietary licenses
==================== ====================
A non-discriminatory license is available for companies that want to include A non-exclusive license is available for companies that want to include
psycopg in their proprietary products without respecting the spirit of the psycopg in their proprietary products without respecting the spirit of the
GPL. The price of the license is one day of development done by the author, GPL. The price of the license is one day of development done by the author,
at the consulting fee he applies to his usual customers at the day of the at the consulting fee he applies to his usual customers at the day of the

24
README
View File

@ -21,25 +21,5 @@ compile on all architectures just as its predecessor did.
Now go read the INSTALL file. More information about psycopg extensions to Now go read the INSTALL file. More information about psycopg extensions to
the DBAPI-2.0 is available in the files located in the doc/ direcory. the DBAPI-2.0 is available in the files located in the doc/ direcory.
psycopg is free software ("free as in freedom" but I like beer too.)
Licence Licensing information is available in the LICENSE file.
-------
psycopg is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version. See file COPYING for details.
As a special exception, specific permission is granted for the GPLed code in
this distribition to be linked to OpenSSL and PostgreSQL libpq without
invoking GPL clause 2(b).
If you prefer you can use the Zope Database Adapter ZPsycopgDA (i.e., every
file inside the ZPsycopgDA directory) under the ZPL license as published on
the Zope web site, http://www.zope.org/Resources/ZPL. The ZPL is perfectly
compatible with the GPL
psycopg is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.

View File

@ -95,7 +95,7 @@ typecast_parse_time(char* s, char** t, int* len,
Dprintf("typecast_parse_time: len = %d, s = %s", *len, s); Dprintf("typecast_parse_time: len = %d, s = %s", *len, s);
while (cz < 5 && *len > 0 && *s) { while (cz < 6 && *len > 0 && *s) {
switch (*s) { switch (*s) {
case ':': case ':':
if (cz == 0) *hh = acc; if (cz == 0) *hh = acc;

View File

@ -1,5 +1,5 @@
[build_ext] [build_ext]
define=PSYCOPG_EXTENSIONS,PSYCOPG_DISPLAY_SIZE,HAVE_PQFREEMEM,HAVE_PQPROTOCOL3 define=PSYCOPG_DEBUG,PSYCOPG_EXTENSIONS,PSYCOPG_DISPLAY_SIZE,HAVE_PQFREEMEM,HAVE_PQPROTOCOL3
# PSYCOPG_EXTENSIONS enables extensions to PEP-249 (you really want this) # PSYCOPG_EXTENSIONS enables extensions to PEP-249 (you really want this)
# PSYCOPG_DISPLAY_SIZE enable display size calculation (a little slower) # PSYCOPG_DISPLAY_SIZE enable display size calculation (a little slower)
# HAVE_PQFREEMEM should be defined on PostgreSQL >= 7.3 # HAVE_PQFREEMEM should be defined on PostgreSQL >= 7.3