From 146393cf11b20dc8bf11c3eb5746b6ecd5ce4675 Mon Sep 17 00:00:00 2001 From: Fabrice Bellet Date: Tue, 2 Dec 2014 23:12:44 +0100 Subject: debug: fix a string overflow in comments --- src/emu/debug/dvdisasm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/emu/debug/dvdisasm.c b/src/emu/debug/dvdisasm.c index cba167a2160..3630ba28f07 100644 --- a/src/emu/debug/dvdisasm.c +++ b/src/emu/debug/dvdisasm.c @@ -420,7 +420,7 @@ bool debug_view_disasm::recompute(offs_t pc, int startline, int lines) offs_t comment_address = source.m_space.byte_to_address(m_byteaddress[instr]); const char *text = source.m_device.debug()->comment_text(comment_address); if (text != NULL) - sprintf(&destbuf[m_divider2], "// %.*s", row_width - m_divider2 - 1, text); + sprintf(&destbuf[m_divider2], "// %.*s", row_width - m_divider2 - 4, text); } // see if the line changed at all -- cgit v1.2.3