[PATCH] vi: fix undo when ':s' replacement string is empty
rmy at pobox.com
Tue Jul 13 15:16:59 UTC 2021
Denys Vlasenko wrote:
>I missed this one, and then this part was rewritten in
>"allow regular expressions in ':s' commands".
>Sorry about the mess.
No worries. Looks OK at first glance, though only time and continued
dogfooding of BusyBox vi will tell.
I think we may have ended up with a superfluous line. Unless it was
editors/vi.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/editors/vi.c b/editors/vi.c
index c6bb74cfb..ce5740e49 100644
@@ -3243,7 +3243,6 @@ static void colon(char *buf)
TEST_UNDO2 ? ALLOW_UNDO_CHAIN: ALLOW_UNDO);
found += bias;
ls += bias;
- dot = ls;
//q += bias; - recalculated anyway
# if ENABLE_FEATURE_VI_REGEX_SEARCH
More information about the busybox