alexis-soluteo / bizhawk

Automatically exported from code.google.com/p/bizhawk
0 stars 0 forks source link

Single instance mode issues #288

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I've noticed 2 issues when enabling single instance:
- the 2nd instance crashes instead of diying
- the app freezes when pressing "exit key" (manually quitting the app is ok)

Original issue reported on code.google.com by baptiste...@gadz.org on 14 Oct 2014 at 8:51

GoogleCodeExporter commented 9 years ago
I did not see my Single Instance crash.  EmuHawk was told it's single instance 
and then reloaded in Single Instance mode.  Loading EmuHawk if the old instance 
is not told to be single instance and the mode is set.

Original comment by hegyak on 17 Oct 2014 at 12:01

GoogleCodeExporter commented 9 years ago
I've made a test launching the 2nd instance from Visual Studio in debug mode.
Here is where it stops:

Original comment by baptiste...@gmail.com on 17 Oct 2014 at 5:23

Attachments:

GoogleCodeExporter commented 9 years ago
Pressing a custom "Exit key" when single instance mode is enabled does not get 
you a crash: the emulation stops but the windows stays on until you manually 
close it.

Original comment by baptiste...@gmail.com on 17 Oct 2014 at 5:26

GoogleCodeExporter commented 9 years ago
Confirmed on SVN Build r8178

Reproduction Steps:
Enable Single Instance Mode and close EmuHawk fully.
Reopen EmuHawk.
Attempt to open another Instance of EmuHawk.
Error message and First instance freezes until the error message is cleared.

I get this error:
************** Exception Text **************
System.ArgumentOutOfRangeException: Index was out of range. Must be 
non-negative and less than the size of the collection.
Parameter name: index
   at System.ThrowHelper.ThrowArgumentOutOfRangeException()
   at System.SZArrayHelper.get_Item[T](Int32 index)
   at BizHawk.Client.EmuHawk.Program.SingleInstanceController.this_StartupNextInstance(Object sender, StartupNextInstanceEventArgs e)
   at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.OnStartupNextInstance(StartupNextInstanceEventArgs eventArgs)
   at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.OnStartupNextInstanceMarshallingAdaptor(Object args)

Close Emulator hotkey appears to be working fine for me in single instance mode.

Original comment by hegyak on 15 Nov 2014 at 3:41

GoogleCodeExporter commented 9 years ago
The two crashes are fixed in r8661.

Original comment by jdpurcell on 29 Dec 2014 at 4:41