change the replacement algoricthm to only replace when:
authorKeith Bostic <bostic@ucbvax.Berkeley.EDU>
Thu, 21 Apr 1994 05:51:51 +0000 (21:51 -0800)
committerKeith Bostic <bostic@ucbvax.Berkeley.EDU>
Thu, 21 Apr 1994 05:51:51 +0000 (21:51 -0800)
commitb436b07a0808599b89f1e9e273cfcb886fca41e4
treea22bb9f498362464cd62032da62328c23d89a44b
parent2df6faf76dd80742879ff24330adb99a64d5b69b
change the replacement algoricthm to only replace when:
(1) the previous replacement was for an empty match, or
(2) the current replacement is for a non-empty match.
this makes empty RE's work as they did historically
From: "Chris G. Demetriou" <cgd@sun-lamp.cs.berkeley.edu>

SCCS-vsn: usr.bin/sed/process.c 8.5
usr/src/usr.bin/sed/process.c