bore

basic core utilities (PD)
git clone git://bvnf.space/bore.git
Log | Files | Refs | README

commit 3368cfb395cf7e5ee04a067444707d2e2297d3a7
parent f879a55e9b435260e81455e5814483dcc218e2cd
Author: phoebos <ben@bvnf.space>
Date:   Tue, 11 Oct 2022 11:13:34 +0100

ed: getopt returns -1 not EOF

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

diff --git a/ed.c b/ed.c @@ -326,7 +326,7 @@ main(int argc, char **argv) { first->prev = first; first->s = NULL; first->len = 0; - while ((c = getopt(argc, argv, "p:s")) != EOF) { + while ((c = getopt(argc, argv, "p:s")) != -1) { switch (c) { case 's': s_flag = 1;