[hatari-devel] saving/restoring memory state from debugger

Eero Tamminen eerot at users.berlios.de
Sat Feb 13 21:18:19 CET 2010


Hi,

On Saturday 13 February 2010, npomarede at corp.free.fr wrote:
> >> In fact, it seems that only the first statesave when entering debug
> >> with altgr+pause doesn't return to prompt ; if I try other statesave
> >> (with or without tab) then it works. So, this is not related to
> >> completion.
> >
> > Can you send you Hatari config file and tell which command line
> > arguments you're using?
>
> Here it is ; I'm just running ./hatari without any args.
>
> (the problem is there even if I compile Hatari without readline support)

Debugger uses the normal MemorySnapShot_Capture() function to do the state
saving.  Because that doesn't return any success/fail value, debugger gives
it an argument that makes it to print message about saving success.

It does that using:
	Log_AlertDlg(LOG_INFO, "Memory state file saved.");

With the default Hatari settings that will just print the message to
console.  You have set an alert level which shows this also as an alert on
screen.

Instead of using ^C in debugger, you can just press Enter in Hatari window
for the dialog to go away and Hatari to continue.


I could:
- Remove that flag from MemorySnapShot_Capture/Restore() calls
- Change them to return a bool about success
- Output a message from debugger itself based on this return value.

But I wonder whether alerts should be completely disabled while one is in
debugger.  Is there any reason why one should get an alert from debugger
command in addition to console message (log messages can be re-directed
to a file)?


	- Eero



More information about the hatari-devel mailing list