ed

simple ed
git clone git://git.2f30.org/ed
Log | Files | Refs | LICENSE

commit c1fe870e7fa5c1a164a69c2f5aa6b3b2d6fa4d58
parent 0b48c28715bcc07187be5d35c5b832537bf51f18
Author: Roberto E. Vargas Caballero <k0ga@shike2.com>
Date:   Mon, 14 Dec 2015 09:28:27 +0100

Remove call to getchar() in linenum()

This is totally incorrect, because linenum()
can be called from docmd() with the string of a
previous command, so we have to call to input()

Diffstat:
Med.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/ed.c b/ed.c @@ -449,7 +449,7 @@ linenum(int *line) break; case '\'': skipblank(); - if (!isalpha(c = getchar())) + if (!isalpha(c = input())) error("invalid mark character"); if (!(ln = marks[c])) error("invalid address");