[pywin32-checkins] /hgrepo/p/py/pywin32/pywin32: bugfix ID: 3292681 Subtle crash
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
From: <pyw...@li...> - 2011-04-30 03:40:30
|
changeset 521b09dc35f8 in /hgrepo/p/py/pywin32/pywin32 details: http://pywin32.hg.sourceforge.net/hgweb/pywin32/pywin32/hgrepo/p/py/pywin32/pywin32?cmd=changeset;node=521b09dc35f8 summary: bugfix ID: 3292681 Subtle crash diffstat: adodbapi/adodbapi.py | 15 ++++++++------- 1 files changed, 8 insertions(+), 7 deletions(-) diffs (39 lines): diff -r 1f726f95d353 -r 521b09dc35f8 adodbapi/adodbapi.py --- a/adodbapi/adodbapi.py Sun Apr 24 17:41:43 2011 +1000 +++ b/adodbapi/adodbapi.py Fri Apr 29 21:40:01 2011 -0600 @@ -26,7 +26,7 @@ or IronPython version 2.6 and later, or, after running through 2to3.py, CPython 3.0 or later. """ -__version__ = '2.4.2.0' +__version__ = '2.4.2.2' version = 'adodbapi v' + __version__ # N.O.T.E.:... # if you have been using an older version of adodbapi and are getting errors because @@ -395,10 +395,12 @@ p.AppendChunk(value) elif isinstance(value, decimal.Decimal): - ##s = str(value) - ##p.Value = s - ##p.Size = len(s) - p.Value = value + if onIronPython: + s = str(value) + p.Value = s + p.Size = len(s) + else: + p.Value = value exponent = value.as_tuple()[2] digit_count = len(value.as_tuple()[1]) p.Precision = digit_count @@ -496,8 +498,7 @@ self._closeAdoConnection() #v2.1 Rose except (Exception), e: self._raiseConnectionError(InternalError,e) - if not onIronPython: - pythoncom.CoUninitialize() #v2.1 Paj + self.adoConn = None #v2.4.2.2 fix subtle timeout bug def commit(self): """Commit any pending transaction to the database. |