diff options
| author | Federico Di Gregorio <fog@initd.org> | 2007-12-21 00:18:55 +0000 |
|---|---|---|
| committer | Federico Di Gregorio <fog@initd.org> | 2007-12-21 00:18:55 +0000 |
| commit | d31b4add22debc3f9f691bb7aee8aae0a774a656 (patch) | |
| tree | 2c5642c13b1daa5901dea82ae3edcdb48c32ce1e /psycopg/psycopgmodule.c | |
| parent | 4910f53b7eb33580fcc97f0fad746071f5806839 (diff) | |
| download | psycopg2-d31b4add22debc3f9f691bb7aee8aae0a774a656.tar.gz | |
Applied win32 patch from Jason Erickson.
Diffstat (limited to 'psycopg/psycopgmodule.c')
| -rw-r--r-- | psycopg/psycopgmodule.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/psycopg/psycopgmodule.c b/psycopg/psycopgmodule.c index 43b9ea3..2c4be8c 100644 --- a/psycopg/psycopgmodule.c +++ b/psycopg/psycopgmodule.c @@ -593,6 +593,7 @@ psyco_GetDecimalType(void) static PyObject *cachedType = NULL; #ifdef HAVE_DECIMAL + PyObject *decimal = PyImport_ImportModule("decimal"); /* Use the cached object if running from the main interpreter. */ int can_cache = psyco_is_main_interp(); @@ -602,7 +603,6 @@ psyco_GetDecimalType(void) } /* Get a new reference to the Decimal type. */ - PyObject *decimal = PyImport_ImportModule("decimal"); if (decimal) { decimalType = PyObject_GetAttrString(decimal, "Decimal"); Py_DECREF(decimal); |
