CEmu icon indicating copy to clipboard operation
CEmu copied to clipboard

CEmu sometimes doesn't open.

Open Zexxerd opened this issue 4 years ago • 2 comments

(Thanks for reporting an issue! Please make sure to fill out the blanks below.)

What's wrong, and with what software version?

Operating System: MacOS High Sierra (10.13.6) CEmu version: 1.3
Describe your issue: I have had CEmu on my computer for a few months, now. Sometimes, I expect CEmu to open to the emulator, but other times, CEmu just quits without doing anything. Even if I uninstall and reinstall CEmu, it still just closes.

What are the steps to reproduce this issue?

  1. Get a Mac.
  2. Open CEmu on it.
  3. See if it opens.

Any logs, error output, screenshot, other comments...?

No

Zexxerd avatar Oct 07 '19 21:10 Zexxerd

Well that's not going to be very easy to debug... You could try resetting/removing all CEmu config files and see if that helps. In fact you can do that with the menu item "Reset CEmu" when you manage to get it launched.

adriweb avatar Oct 08 '19 11:10 adriweb

I'm having a similar issue on Linux Mint. Mine seems to occur whenever I shut down my computer without first properly closing CEmu. When restarting CEmu, it notices the previous instance file (~/.config/cemu-dev/CEmu/id/Calculator) which was not deleted because CEmu did not exit properly. I assume that the issue is that CEmu tries to start IPC rather than starting a new instance with that id. According to (https://github.com/CE-Programming/CEmu/blob/master/gui/qt/ipc.cpp), if the process with the PID specified in the id file does not exist, it removes the ID file. The file is not removed if the process is not a CEmu instance.

If the system has restarted or if PIDs are being reused, a situation could occur where the PID in the id file refers to an extant process, but not a CEmu instance. This means that the IPC would fail, the bad ID file would not be removed, and CEmu would fail to open while giving no feedback for why it isn't opening. I assume this is what is happening here.

This could possibly be fixed by checking if the process actually belongs to a CEmu instance when determining if the file should be deleted, or by giving the user the option to delete the potentially bad id file when the IPC connection fails.

As a hackfix, you could remove the invalid file with rm ~/.config/cemu-dev/CEmu/id/Calculator each time this issue occurs.

commandblockguy avatar Oct 15 '19 00:10 commandblockguy