From aea39acc84741eb2fa868865e9fdc0395fa94478 Mon Sep 17 00:00:00 2001 From: Robin Haberkorn Date: Tue, 22 Jan 2013 19:26:45 +0100 Subject: fixed: macro program counter is fixed after error occurred while executing commandline fixes errors in loops or loop interruptions (may leave program counter somewhere in the loop) --- TODO | 4 ++-- src/cmdline.cpp | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/TODO b/TODO index 9b2578c..6b3cf39 100644 --- a/TODO +++ b/TODO @@ -1,6 +1,6 @@ Known Bugs: - * Dot is not always restored properly (e.g. after closing file) - * Strange behaviour after loop interruption (e.g. "<%a>") + * ??? Dot is not always restored properly (e.g. after closing file) + need test case!!! * Null-byte in strings not always handled transparently * saving another user's file will only preserve the user when run as root (WON'T FIX!?) diff --git a/src/cmdline.cpp b/src/cmdline.cpp index ddfe791..f36aab5 100644 --- a/src/cmdline.cpp +++ b/src/cmdline.cpp @@ -101,6 +101,8 @@ cmdline_keypress(gchar key) */ undo.pop(cmdline_p - cmdline); cmdline_p[-1] = '\0'; + /* program counter could be messed up */ + macro_pc = cmdline_p - cmdline - 1; break; } } -- cgit v1.2.3