Bug #115462 grt.dll crashes workbench trying to connect to a database
Submitted: 29 Jun 2024 15:41 Modified: 1 Aug 2024 12:43
Reporter: Heinz Schweitzer (Gold Quality Contributor) Email Updates:
Status: No Feedback Impact on me:
None 
Category:MySQL Workbench Severity:S2 (Serious)
Version:8.0.36.0 OS:Windows (11)
Assigned to: MySQL Verification Team CPU Architecture:x86

[29 Jun 2024 15:41] Heinz Schweitzer
Description:
Connecting to the server is no problem, but connecting to a database crashes
workbench.

Below is message from windows event log. 
Server-Version: 8.4.0 - MySQL Community Server - GPL

Protokollname: Application
Quelle:        Application Error
Datum:         29.06.2024 17:33:09
Ereignis-ID:   1000
Aufgabenkategorie:Anwendungsabsturzereignisse
Ebene:         Fehler
Schlüsselwörter:
Benutzer:      HEINZ-PC\Heinz
Computer:      Heinz-PC
Beschreibung:
Name der fehlerhaften Anwendung: MySQLWorkbench.exe, Version: 8.0.36.0, Zeitstempel: 0x65836021
Name des fehlerhaften Moduls: grt.dll, Version: 0.0.0.0, Zeitstempel: 0x65835f3c
Ausnahmecode: 0xc0000005
Fehleroffset: 0x000000000000cd63
ID des fehlerhaften Prozesses: 0x0x19C8
Startzeit der fehlerhaften Anwendung: 0x0x1DACA38088C72D6
Pfad der fehlerhaften Anwendung: C:\Program Files\MySQL\MySQL Workbench 8.0 CE\MySQLWorkbench.exe
Pfad des fehlerhaften Moduls: C:\Program Files\MySQL\MySQL Workbench 8.0 CE\grt.dll
Berichtskennung: ff1397ce-f5be-4436-bf5a-b1ca3fdb8e60
Vollständiger Name des fehlerhaften Pakets: 
Anwendungs-ID, die relativ zum fehlerhaften Paket ist: 
Ereignis-XML:
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
  <System>
    <Provider Name="Application Error" Guid="{a0e9b465-b939-57d7-b27d-95d8e925ff57}" />
    <EventID>1000</EventID>
    <Version>0</Version>
    <Level>2</Level>
    <Task>100</Task>
    <Opcode>0</Opcode>
    <Keywords>0x8000000000000000</Keywords>
    <TimeCreated SystemTime="2024-06-29T15:33:09.6787586Z" />
    <EventRecordID>3503480</EventRecordID>
    <Correlation />
    <Execution ProcessID="17540" ThreadID="3800" />
    <Channel>Application</Channel>
    <Computer>Heinz-PC</Computer>
    <Security UserID="S-1-5-21-3430671757-2969678178-3540373988-1001" />
  </System>
  <EventData>
    <Data Name="AppName">MySQLWorkbench.exe</Data>
    <Data Name="AppVersion">8.0.36.0</Data>
    <Data Name="AppTimeStamp">65836021</Data>
    <Data Name="ModuleName">grt.dll</Data>
    <Data Name="ModuleVersion">0.0.0.0</Data>
    <Data Name="ModuleTimeStamp">65835f3c</Data>
    <Data Name="ExceptionCode">c0000005</Data>
    <Data Name="FaultingOffset">000000000000cd63</Data>
    <Data Name="ProcessId">0x19c8</Data>
    <Data Name="ProcessCreationTime">0x1daca38088c72d6</Data>
    <Data Name="AppPath">C:\Program Files\MySQL\MySQL Workbench 8.0 CE\MySQLWorkbench.exe</Data>
    <Data Name="ModulePath">C:\Program Files\MySQL\MySQL Workbench 8.0 CE\grt.dll</Data>
    <Data Name="IntegratorReportId">ff1397ce-f5be-4436-bf5a-b1ca3fdb8e60</Data>
    <Data Name="PackageFullName">
    </Data>
    <Data Name="PackageRelativeAppId">
    </Data>
  </EventData>
</Event>

other message

Protokollname: Application
Quelle:        .NET Runtime
Datum:         29.06.2024 17:33:09
Ereignis-ID:   1026
Aufgabenkategorie:Keine
Ebene:         Fehler
Schlüsselwörter:Klassisch
Benutzer:      Nicht zutreffend
Computer:      Heinz-PC
Beschreibung:
Anwendung: MySQLWorkbench.exe
Frameworkversion: v4.0.30319
Beschreibung: Der Prozess wurde aufgrund einer unbehandelten Ausnahme beendet.
Ausnahmeinformationen: System.AccessViolationException
   bei <Module>.mforms.MenuItem.callback(mforms.MenuItem*)
   bei MenuItemEventTarget.MenuItemClick(System.Object, System.EventArgs)
   bei System.Windows.Forms.ToolStripItem.RaiseEvent(System.Object, System.EventArgs)
   bei System.Windows.Forms.ToolStripMenuItem.OnClick(System.EventArgs)
   bei System.Windows.Forms.ToolStripItem.HandleClick(System.EventArgs)
   bei System.Windows.Forms.ToolStripItem.HandleMouseUp(System.Windows.Forms.MouseEventArgs)
   bei System.Windows.Forms.ToolStrip.OnMouseUp(System.Windows.Forms.MouseEventArgs)
   bei System.Windows.Forms.ToolStripDropDown.OnMouseUp(System.Windows.Forms.MouseEventArgs)
   bei System.Windows.Forms.Control.WmMouseUp(System.Windows.Forms.Message ByRef, System.Windows.Forms.MouseButtons, Int32)
   bei System.Windows.Forms.Control.WndProc(System.Windows.Forms.Message ByRef)
   bei System.Windows.Forms.ToolStrip.WndProc(System.Windows.Forms.Message ByRef)
   bei System.Windows.Forms.ToolStripDropDown.WndProc(System.Windows.Forms.Message ByRef)
   bei System.Windows.Forms.NativeWindow.Callback(IntPtr, Int32, IntPtr, IntPtr)
   bei System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG ByRef)
   bei System.Windows.Forms.Application+ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr, Int32, Int32)
   bei System.Windows.Forms.Application+ThreadContext.RunMessageLoopInner(Int32, System.Windows.Forms.ApplicationContext)
   bei System.Windows.Forms.Application+ThreadContext.RunMessageLoop(Int32, System.Windows.Forms.ApplicationContext)
   bei MySQL.GUI.Workbench.Program.Main(System.String[])

Ereignis-XML:
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
  <System>
    <Provider Name=".NET Runtime" />
    <EventID Qualifiers="0">1026</EventID>
    <Version>0</Version>
    <Level>2</Level>
    <Task>0</Task>
    <Opcode>0</Opcode>
    <Keywords>0x80000000000000</Keywords>
    <TimeCreated SystemTime="2024-06-29T15:33:09.4676113Z" />
    <EventRecordID>3503479</EventRecordID>
    <Correlation />
    <Execution ProcessID="6600" ThreadID="0" />
    <Channel>Application</Channel>
    <Computer>Heinz-PC</Computer>
    <Security />
  </System>
  <EventData>
    <Data>Anwendung: MySQLWorkbench.exe
Frameworkversion: v4.0.30319
Beschreibung: Der Prozess wurde aufgrund einer unbehandelten Ausnahme beendet.
Ausnahmeinformationen: System.AccessViolationException
   bei &lt;Module&gt;.mforms.MenuItem.callback(mforms.MenuItem*)
   bei MenuItemEventTarget.MenuItemClick(System.Object, System.EventArgs)
   bei System.Windows.Forms.ToolStripItem.RaiseEvent(System.Object, System.EventArgs)
   bei System.Windows.Forms.ToolStripMenuItem.OnClick(System.EventArgs)
   bei System.Windows.Forms.ToolStripItem.HandleClick(System.EventArgs)
   bei System.Windows.Forms.ToolStripItem.HandleMouseUp(System.Windows.Forms.MouseEventArgs)
   bei System.Windows.Forms.ToolStrip.OnMouseUp(System.Windows.Forms.MouseEventArgs)
   bei System.Windows.Forms.ToolStripDropDown.OnMouseUp(System.Windows.Forms.MouseEventArgs)
   bei System.Windows.Forms.Control.WmMouseUp(System.Windows.Forms.Message ByRef, System.Windows.Forms.MouseButtons, Int32)
   bei System.Windows.Forms.Control.WndProc(System.Windows.Forms.Message ByRef)
   bei System.Windows.Forms.ToolStrip.WndProc(System.Windows.Forms.Message ByRef)
   bei System.Windows.Forms.ToolStripDropDown.WndProc(System.Windows.Forms.Message ByRef)
   bei System.Windows.Forms.NativeWindow.Callback(IntPtr, Int32, IntPtr, IntPtr)
   bei System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG ByRef)
   bei System.Windows.Forms.Application+ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr, Int32, Int32)
   bei System.Windows.Forms.Application+ThreadContext.RunMessageLoopInner(Int32, System.Windows.Forms.ApplicationContext)
   bei System.Windows.Forms.Application+ThreadContext.RunMessageLoop(Int32, System.Windows.Forms.ApplicationContext)
   bei MySQL.GUI.Workbench.Program.Main(System.String[])

</Data>
  </EventData>
</Event>

How to repeat:
try connecting to a datbase
[29 Jun 2024 15:42] Heinz Schweitzer
typo
[1 Jul 2024 12:43] MySQL Verification Team
Hello Heinz Schweitzer,

Thank you for the bug report.
To investigate further this issue at our end, may I kindly request you to launch workbench under debug mode (--log-level=debug3) and provide unaltered workbench log file(more details about log are explained here - https://dev.mysql.com/doc/workbench/en/workbench-reporting-bugs.html)?

Regards,
Ashwini Patil
[2 Aug 2024 1:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
[2 Jun 13:03] Matthew Baker
This is still occurring in v8.0.42.

I am connecting to a MySQL Enterprise - Cloud 8.4.0-u7-cloud server.

The crash only occurs if I use the Database -> Connect to Database… option.
Connecting via the saved connection tile in the main screen works fine.

Log attached using --log-level=debug3

Application exit message:
```
Unhandled Exception: System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
   at mforms.MenuItem.callback(MenuItem* )
   at MenuItemEventTarget.MenuItemClick(Object sender, EventArgs e)
   at System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
   at System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
   at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
   at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
   at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
   at System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
   at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ToolStrip.WndProc(Message& m)
   at System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
   at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
   at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)
   at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
   at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
   at MySQL.GUI.Workbench.Program.Main(String[] Args)
```