Subject: bin/730: ed 1,$s/a/b/p command prints wrong line.
To: None <gnats-admin@NetBSD.ORG>
From: John F. Woods <jfw@jfwhome.funhouse.com>
List: netbsd-bugs
Date: 01/13/1995 11:50:04
>Number: 730
>Category: bin
>Synopsis: ed 1,$s/a/b/p command prints wrong line.
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: bin-bug-people (Utility Bug People)
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Fri Jan 13 11:50:02 1995
>Originator: John F. Woods
>Organization:
Misanthropes-R-Us
>Release: NetBSD-current January 1 1995
>Environment:
System: NetBSD jfwhome.funhouse.com 1.0A NetBSD 1.0A (JFW) #14: Wed Jan 4 22:53:11 EST 1995 root@jfwhome.funhouse.com:/usr/src/sys/arch/i386/compile/JFW i386
>Description:
The substitute command in ed, when operating on multiple lines, ends on the wrong line;
it should put the current line on the last line changes, not the last line of the range.
>How-To-Repeat:
Take any file, do a successful 1,$s/something/somethingelse/p operation, where
something is not found on the last line. Note that it prints the last line, rather
than the last changed line.
>Fix:
I'll look into it later, if no one else does.
>Audit-Trail:
>Unformatted: