Up to [local] / src / usr.bin / mg
Request diff between arbitrary revisions
Default branch: MAIN
Current tag: OPENBSD_6_8_BASE
Revision 1.35 / (download) - annotate - [select for diffs], Wed Jul 22 13:29:05 2020 UTC (3 years, 10 months ago) by tb
Branch: MAIN
CVS Tags: OPENBSD_6_9_BASE,
OPENBSD_6_9,
OPENBSD_6_8_BASE,
OPENBSD_6_8
Changes since 1.34: +9 -5 lines
Diff to previous 1.34 (colored)
Avoid running out of memory with query-replace-regex ^ Choosing ! (replace rest) never advances beyond the current line and keeps inserting the replacement test, and mg eventually runs out of memory. Patch from Mark Willson with minor stylistic tweaks. Looks good to Hiltjo Posthuma who would have preferred making forward replacing on empty lines work. Mark argued that this makes it behave consistently with the current behaviour when searching for ^ and the point at the beginning of a non-empty line in which case the cursor does not move either. Also tested by krw