diff options
author | Jason Erickson <jerickso@stickpeople.com> | 2010-05-16 15:20:22 -0600 |
---|---|---|
committer | Federico Di Gregorio <fog@initd.org> | 2010-05-17 09:06:14 +0200 |
commit | 1f1133b8714d1f6e5da656eddb3c6ff62f5e3570 (patch) | |
tree | 7bcf1301765ce5c362fa174c61c1d8b975312998 /psycopg/connection_int.c | |
parent | e286970b625095334ce14a8c0a8a857f914ab53d (diff) | |
download | psycopg2-1f1133b8714d1f6e5da656eddb3c6ff62f5e3570.tar.gz |
Micrsoft Visual C Compile Fix
Moved the declarations of variables/pointers to the beginning of the block, where MSVC wants them.
Diffstat (limited to 'psycopg/connection_int.c')
-rw-r--r-- | psycopg/connection_int.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/psycopg/connection_int.c b/psycopg/connection_int.c index 31a68d5..902fdbb 100644 --- a/psycopg/connection_int.c +++ b/psycopg/connection_int.c @@ -256,6 +256,7 @@ int conn_setup(connectionObject *self, PGconn *pgconn) { PGresult *pgres; + int green; self->equote = conn_get_standard_conforming_strings(pgconn); self->server_version = conn_get_server_version(pgconn); @@ -265,7 +266,7 @@ conn_setup(connectionObject *self, PGconn *pgconn) pthread_mutex_lock(&self->lock); Py_BLOCK_THREADS; - int green = psyco_green(); + green = psyco_green(); if (green && (pq_set_non_blocking(self, 1, 1) != 0)) { return -1; |