From d3c5f2939de4b0d4f731898844dcafbc8e64734b Mon Sep 17 00:00:00 2001 From: Nathan Woods Date: Sat, 24 Jun 2017 09:39:55 -0400 Subject: Fixed an issue that could cause the debugger 'source' command to falsely display I/O error I've discovered a scenario where reading to the end of file seems to trigger the fail bit, in addition to the eof bit. Because of this, I've changed the error message to display when we can't read from the stream, but the eof bit is _not_ set --- src/emu/debug/debugcpu.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/emu/debug/debugcpu.cpp b/src/emu/debug/debugcpu.cpp index 2773c66fda5..3335f19ff3e 100644 --- a/src/emu/debug/debugcpu.cpp +++ b/src/emu/debug/debugcpu.cpp @@ -893,7 +893,7 @@ void debugger_cpu::process_source_file() if (m_source_file && !m_source_file->good()) { - if (m_source_file->fail()) + if (!m_source_file->eof()) m_machine.debugger().console().printf("I/O error, script processing terminated\n"); m_source_file.reset(); } -- cgit v1.2.3