Menu

#22 SQLAllocConnect() doesn't save environment handle

closed-fixed
None
5
2007-10-07
2007-05-25
Kent Boortz
No

While the environment handle is passed to
SQLAllocConnect(), the ->henv field is set
to SQL_NULL_HENV. Maybe that is correct, but
calling SQLSetConnectAttr() this field is
assumed to be set to a pointer, not NULL.

SQLUINTEGER dodbc_ver = ((ENV_t *) con->henv)->dodbc_ver;

This is libiodbc-3.52.5

Discussion

  • iODBC Maintainer

    • assigned_to: nobody --> iodbc
    • status: open --> closed-fixed
     
  • iODBC Maintainer

    Logged In: YES
    user_id=872639
    Originator: NO

    It is supposed to be set to SQL_NULL_HENV, but the check inside SQLSetConnectAttr and other places was wrong.

    This has been fixed in the upcoming version 3.52.6