Bug #41930 Workbench Crash unexpectedly
Submitted: 7 Jan 2009 19:11 Modified: 22 Mar 2012 17:45
Reporter: Rodrigo Olivares Email Updates:
Status: No Feedback Impact on me:
None 
Category:MySQL Workbench Severity:S2 (Serious)
Version:5.0.30, 5.2.34 OS:Windows
Assigned to: CPU Architecture:Any
Tags: AccessViolationException, CHECKED, crash, Memory

[7 Jan 2009 19:11] Rodrigo Olivares
Description:
When I try to modify a table, workbench crash randomly.
May times , If only open the model and move the table objects, do not ocurrs error and I can save the new table positions.

I don't know if my computer problem or specifically my model is corrupted.

Is not a large model, and my PC have 2GB RAM. 

How to repeat:
Open the model attached, and browse the model making double click in tables to edit them.

Sometimes open the model and changing to "My SQL model" tab is enougth to reproduce the crash.

Is really a phisical memory problem?, is going out of memory or crashing with other program?

Help please.

Suggested fix:
If really is a memory problem with my pc, handle the exception and Close the progrma softly.
[7 Jan 2009 19:12] Rodrigo Olivares
Screenshot1

Attachment: captura1.JPG (image/jpeg, text), 193.07 KiB.

[7 Jan 2009 19:13] Rodrigo Olivares
Error for first screenshot

Attachment: error1.txt (text/plain), 8.58 KiB.

[7 Jan 2009 19:13] Rodrigo Olivares
Screenshot 2

Attachment: captura2.JPG (image/jpeg, text), 188.55 KiB.

[7 Jan 2009 19:14] Rodrigo Olivares
Error for second screenshot

Attachment: error2.txt (text/plain), 8.09 KiB.

[7 Jan 2009 19:33] Rodrigo Olivares
Usually ocurrs when is active "Automatically reopen last model" in options.
[7 Jan 2009 21:16] MySQL Verification Team
WB CPU Usage

Attachment: WB-CPU-USAGE.PNG (image/png, text), 29.49 KiB.

[7 Jan 2009 21:22] MySQL Verification Team
Thank you for the bug report. I couldn't repeat the crash but I noticed when double click the tables the CPU usage arises to 100% and keeps WB freezing for some seconds. Changing between the MySQL Model and the Diagram Screen after a few double click on the tables is more aggressive the CPU usage. I attached a picture showing the task manager.
[8 Jan 2009 11:22] Rodrigo Olivares
Is no easy repeat the crash, maybe my PC have a lot of importence in the bug.

I uncheck the option "Automatically reopen last opened model whem started" in the General Tab in WB Options, and the crash do not sucess.

Maybe there are a little diference between the automatically open and the manually open around the memory usage or something.

I check the option and the crash is repeated.

A mistery for me, but for now I left uncheked this option.
[8 Jan 2009 13:05] MySQL Verification Team
Thank you for the feedback. Now I was able to repeat checking the option "Automatically reopen last opened model whem started".

Consulte o final desta mensagem para obter detalhes sobre como chamar a 
depuração just-in-time (JIT) em vez desta caixa de diálogo.

************** Texto de Exceção **************
System.AccessViolationException: Tentativa de leitura ou gravação em memória protegida. Normalmente, isso é uma indicação de que outra memória está danificada.
   em wb.WBContextUI.get_layer_tree(WBContextUI* , basic_string<char\,std::char_traits<char>\,std::allocator<char> >* )
   em MySQL.Workbench.WbContext.get_layer_tree(String path)
   em MySQL.GUI.Workbench.ModelLayerForm.SetViewTreePath(String path)
   em MySQL.GUI.Workbench.MainForm.mainDockPanel_ActiveDocumentChanged(Object sender, EventArgs e)
   em WeifenLuo.WinFormsUI.Docking.DockPanel.OnActiveDocumentChanged(EventArgs e)
   em WeifenLuo.WinFormsUI.Docking.DockPanel.FocusManagerImpl.RefreshActiveWindow()
   em WeifenLuo.WinFormsUI.Docking.DockPanel.FocusManagerImpl.HookEventHandler(Object sender, HookEventArgs e)
   em WeifenLuo.WinFormsUI.Docking.DockPanel.FocusManagerImpl.LocalWindowsHook.OnHookInvoked(HookEventArgs e)
   em WeifenLuo.WinFormsUI.Docking.DockPanel.FocusManagerImpl.LocalWindowsHook.CoreHookProc(Int32 code, IntPtr wParam, IntPtr lParam)
   em WeifenLuo.WinFormsUI.Docking.NativeMethods.CallNextHookEx(IntPtr hhook, Int32 code, IntPtr wParam, IntPtr lParam)
   em WeifenLuo.WinFormsUI.Docking.DockPanel.FocusManagerImpl.LocalWindowsHook.CoreHookProc(Int32 code, IntPtr wParam, IntPtr lParam)
   em WeifenLuo.WinFormsUI.Docking.NativeMethods.CallNextHookEx(IntPtr hhook, Int32 code, IntPtr wParam, IntPtr lParam)
   em WeifenLuo.WinFormsUI.Docking.DockPanel.FocusManagerImpl.LocalWindowsHook.CoreHookProc(Int32 code, IntPtr wParam, IntPtr lParam)
   em WeifenLuo.WinFormsUI.Docking.NativeMethods.CallNextHookEx(IntPtr hhook, Int32 code, IntPtr wParam, IntPtr lParam)
   em WeifenLuo.WinFormsUI.Docking.DockPanel.FocusManagerImpl.LocalWindowsHook.CoreHookProc(Int32 code, IntPtr wParam, IntPtr lParam)
   em System.Windows.Forms.UnsafeNativeMethods.SetFocus(HandleRef hWnd)
   em System.Windows.Forms.ContainerControl.FocusActiveControlInternal()
   em System.Windows.Forms.ContainerControl.SetActiveControlInternal(Control value)
   em System.Windows.Forms.ContainerControl.SetActiveControl(Control ctl)
   em System.Windows.Forms.ContainerControl.set_ActiveControl(Control value)
   em System.Windows.Forms.Form.SelectInternal(Boolean directed, Boolean forward)
   em System.Windows.Forms.Form.Select(Boolean directed, Boolean forward)
   em System.Windows.Forms.Control.SelectNextControl(Control ctl, Boolean forward, Boolean tabStopOnly, Boolean nested, Boolean wrap)
   em System.Windows.Forms.Control.SelectNextControlInternal(Control ctl, Boolean forward, Boolean tabStopOnly, Boolean nested, Boolean wrap)
   em System.Windows.Forms.Control.SelectNextIfFocused()
   em System.Windows.Forms.Control.SetVisibleCore(Boolean value)
   em System.Windows.Forms.Form.SetVisibleCore(Boolean value)
   em System.Windows.Forms.Control.set_Visible(Boolean value)
   em WeifenLuo.WinFormsUI.Docking.DockContentHandler.SetVisible()
   em WeifenLuo.WinFormsUI.Docking.DockPane.set_ActiveContent(IDockContent value)
   em WeifenLuo.WinFormsUI.Docking.DockPaneStripBase.OnMouseDown(MouseEventArgs e)
   em System.Windows.Forms.Control.WmMouseDown(Message& m, MouseButtons button, Int32 clicks)
   em System.Windows.Forms.Control.WndProc(Message& m)
   em WeifenLuo.WinFormsUI.Docking.DockPaneStripBase.WndProc(Message& m)
   em System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   em System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   em System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

************** Conjuntos de Módulos (Assemblies) Carregados **************
mscorlib
    Versão do Conjunto de Módulos (Assembly): 2.0.0.0
    Versão do Win32: 2.0.50727.1433 (REDBITS.050727-1400)
    Base de Código: file:///c:/WINDOWS/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------
MySQLWorkbench
    Versão do Conjunto de Módulos (Assembly): 5.0.29.3359
    Versão do Win32: 5.0.29.3359
    Base de Código: file:///C:/Arquivos%20de%20programas/MySQL/MySQL%20Workbench%205.0%20OSS/MySQLWorkbench.exe
----------------------------------------
<cut>
[8 Jan 2009 13:36] Rodrigo Olivares
Great!!.

Then is no only my PC.

Maybe the model is corrupted else a WB bug.

Thanks.
[24 Feb 2009 12:04] Rodrigo Olivares
Fixed?

Seems to be corrected in 5.0.30.

Thanks
[4 Mar 2009 11:31] Rodrigo Olivares
Correction, same behavior in 5.0.30.

Thanks
[8 Jun 2009 7:47] Mike Lischke
Please check with version 5.1 of Workbench. We are focussing on WB 5.1 and would like to fix this problem there if it still exists, rather than WB 5.0. Thank you.
[8 Jul 2009 23: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".
[20 Feb 2012 15:22] Jorge Pinho
I started having this problem after a power failure. It crashes when I connect (double-click) on the "local instance", I can start a new model and open the server admin with no problems. If I choose "command line" everything is fine, and I can work perfectly.

I have Win7-64, MySQL 5.5, and WB 5.2.34 CE 7780

Info from SO (in portuguese):

Assinatura do problema:
  Nome do Evento de Problema:	APPCRASH
  Nome da aplicação:	MySQLWorkbench.exe
  Versão da aplicação:	5.2.34.7780
  Carimbo de Data/Hora da Aplicação:	4ddbbfe9
  Nome do Módulo com Falhas:	wbprivate.be.dll
  Versão do Módulo com Falhas:	0.0.0.0
  Carimbo de Data/Hora do Módulo com Falhas:	4ddbbeb7
  Código de excepção:	c0000005
  Desvio de Excepção:	000070ce
  Versão do SO:	6.1.7601.2.1.0.256.48
  ID de Região:	2070
  Informações Adicionais 1:	0a9e
  Informações Adicionais 2:	0a9e372d3b4ad19135b953a78882e789
  Informações Adicionais 3:	0a9e
  Informações Adicionais 4:	0a9e372d3b4ad19135b953a78882e789
[22 Feb 2012 17:45] Valeriy Kravchuk
Please, check if the same problem still happens with a recent version, 5.2.37.
[23 Mar 2012 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".