sync with OpenBSD -current

This commit is contained in:
purplerain 2024-06-18 04:24:39 +00:00
parent 991d31b9d0
commit 99745de747
Signed by: purplerain
GPG key ID: F42C07F07E2E35B7
62 changed files with 774 additions and 285 deletions

View file

@ -1,4 +1,4 @@
/* $OpenBSD: process.c,v 1.35 2022/01/12 15:13:36 martijn Exp $ */
/* $OpenBSD: process.c,v 1.36 2024/06/18 00:32:22 millert Exp $ */
/*-
* Copyright (c) 1992 Diomidis Spinellis.
@ -90,7 +90,7 @@ process(void)
size_t len, oldpsl;
char *p;
for (linenum = 0; mf_fgets(&PS, REPLACE);) {
for (linenum = 0; mf_getline(&PS, REPLACE);) {
pd = 0;
top:
cp = prog;
@ -164,14 +164,14 @@ redirect:
if (!nflag && !pd)
OUT();
flush_appends();
if (!mf_fgets(&PS, REPLACE))
if (!mf_getline(&PS, REPLACE))
exit(0);
pd = 0;
break;
case 'N':
flush_appends();
cspace(&PS, "\n", 1, 0);
if (!mf_fgets(&PS, 0))
if (!mf_getline(&PS, 0))
exit(0);
break;
case 'p':