Patch for C0000005 crash on NULL szSchemaName in allow_public_schema() - Mailing list pgsql-odbc

From Peter Crabtree
Subject Patch for C0000005 crash on NULL szSchemaName in allow_public_schema()
Date
Msg-id AANLkTimDAOJPSebul0QtosTbxH-21aM2Xmwyae7uHRyC@mail.gmail.com
Whole thread Raw
List pgsql-odbc
I've encountered a crash trying to interface Visual FoxPro with
psqlODBC with the ANSI version when getting the structure of a table
without a primary key -- looks like a NULL pointer check was in the
wrong place (strlen() gets called on a not-verified-to-be-non-null
pointer).

I've attached a patch against the current CVS source.

I can't see any way this would impact the rest of the code, as this
function doesn't call any functions with side-effects, and this code
change only changes behavior of the function when it previously would
have crashed, and as such, I haven't done extensive testing, but I
have verified that this fixes the crash in Visual FoxPro, and it runs
fine in my limited testing.

The official FAQ said this is the place to send patches, but please
let me know if that's wrong, or there's anything else I need to do for
patch acceptance, like adding the issue to a tracker or what have you.

Thanks!

Attachment

pgsql-odbc by date:

Previous
From: adishesh machetty
Date:
Subject: unixODBC version
Next
From: James Slater
Date:
Subject: 64Bit Postgres ODBC