Bug #27667 Crash the application using MyODBC 3.51.14 in Vista
Submitted: 5 Apr 2007 14:44 Modified: 15 Apr 2007 13:37
Reporter: Renato Gontijo Email Updates:
Status: Duplicate Impact on me:
Category:Connector / ODBC Severity:S1 (Critical)
Version:3.51.14 OS:Windows (Vista Business)
Assigned to: CPU Architecture:Any
Tags: 3.51.14, crash, ODBC, vista

[5 Apr 2007 14:44] Renato Gontijo
I developed an mini-application to create dsn system. I'm using the VB6 and the

Public Declare Function SQLConfigDataSource Lib "odbccp32.DLL" (ByVal hwndParent
As Long, ByVal fRequest As Long, ByVal lpszDriver As String, ByVal
lpszAttributes As String) As Long

When I try to create ODBC (System DSN) on Vista the app crash.

-- begin example VB 6.0

Public Const ODBC_ADD_DSN_SYS = 4

Private vlstrDriver    As String
Private vlstrAtributos As String

vlstrDriver = "MySQL ODBC 3.51 Driver"

vlstrAtributos = "DSN=DbApp" & chr$(0) & _
                 "Description=MyApp Data Source Name" & chr$(0) & _
                 "Database=MyDB" & chr$(0) & _
                 "SERVER=localhost" & chr$(0) & _
                 "Option=4147" & chr$(0)

lngRet = SQLConfigDataSource(vbAPINULL, ODBC_ADD_DSN_SYS, vlstrDriver,

-- end example VB 6.0

the example bellow works on windows vista to create dsn to MS Access and SQL
Server, but when I try to create to MySQL using MyODBC 3.51.14 the App crashes
like described to other users.

The error is the same of Bug #27315 by Jared Sullivan.

How to repeat:
Try to create an System DSN on Data Source using the API described above.

I guess that if you try to use the API in C++ the system will crash too. All the application used works, including IDE VB 6.0, only MyODBC crashes.
[15 Apr 2007 13:37] Tonci Grgin
Please do not submit the same bug more than once. An existing bug report already describes this very problem. Even if you feel that your issue is somewhat different, the resolution is likely
to be the same. Because of this, we hope you add your comments to the original bug instead.

Thank you for your interest in MySQL.

Explanation: Hi Renato. I have already seen your post in Bug#27315. This is indeed duplicate of that bug so I'm changing status accordingly. A note will be added to Bug#27315.