CC_send_query_append crash

From: Malcolm MacLeod <malcolm(dot)macleod(at)tshwanedje(dot)com>
To: pgsql-odbc(at)postgresql(dot)org
Subject: CC_send_query_append crash
Date: 2014-04-29 16:44:47
Message-ID: 1398789887.4578.19.camel@watchmen.homenetwork
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-odbc


Hello,

While stress testing our software to handle network
reconnects/disconnects I have run into a crash in your ODBC driver.

The crash seems to occur because CC_send_query_append crash takes a
local copy of the pointer 'self->sock' at the top of the function,
'self' is then passed around to various functions (some of which have
the side effect of setting self->sock to NULL (and deleting) if there is
a lost connection) and then the local copy of the pointer (which is now
dangling) is dereferenced lower down in the function.
Essentially if there is a disconnect while CC_send_query_append is
running there is a risk of crash.

I hope that you can fix this soon.

Regards,
Malcolm MacLeod

Attachment Content-Type Size
Dangling_socket_pointer_fix.diff text/x-patch 8.1 KB

Responses

Browse pgsql-odbc by date

  From Date Subject
Next Message Pierre Couderc 2014-04-30 07:23:41 Re: Transcoding problem with wine and unixodbc
Previous Message Adrian Klaver 2014-04-25 23:40:47 Re: Transcoding problem with wine and unixodbc