sync code with last fixes and improvements from OpenBSD

This commit is contained in:
purplerain 2023-07-20 23:56:46 +00:00
parent f57be82572
commit 58b04bcee7
Signed by: purplerain
GPG key ID: F42C07F07E2E35B7
468 changed files with 9958 additions and 7882 deletions

View file

@ -1,4 +1,4 @@
/* $OpenBSD: open_memstream.c,v 1.9 2023/06/21 13:11:49 claudio Exp $ */
/* $OpenBSD: open_memstream.c,v 1.10 2023/07/11 12:14:16 claudio Exp $ */
/*
* Copyright (c) 2011 Martin Pieuchot <mpi@openbsd.org>
@ -135,7 +135,6 @@ open_memstream(char **pbuf, size_t *psize)
return (NULL);
}
*st->string = '\0';
st->pos = 0;
st->len = 0;
st->pbuf = pbuf;

View file

@ -1,4 +1,4 @@
/* $OpenBSD: open_wmemstream.c,v 1.9 2023/06/21 13:11:49 claudio Exp $ */
/* $OpenBSD: open_wmemstream.c,v 1.10 2023/07/11 12:14:16 claudio Exp $ */
/*
* Copyright (c) 2011 Martin Pieuchot <mpi@openbsd.org>
@ -145,7 +145,6 @@ open_wmemstream(wchar_t **pbuf, size_t *psize)
return (NULL);
}
*st->string = L'\0';
st->pos = 0;
st->len = 0;
st->pbuf = pbuf;

View file

@ -1,4 +1,4 @@
.\" $OpenBSD: poll.2,v 1.39 2022/01/21 15:23:36 millert Exp $
.\" $OpenBSD: poll.2,v 1.40 2023/07/18 04:17:17 asou Exp $
.\"
.\" Copyright (c) 1994 Jason R. Thorpe
.\" All rights reserved.
@ -28,7 +28,7 @@
.\" OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\"
.Dd $Mdocdate: January 21 2022 $
.Dd $Mdocdate: July 18 2023 $
.Dt POLL 2
.Os
.Sh NAME
@ -287,9 +287,9 @@ if (nready == -1)
err(1, "poll");
if (nready == 0)
errx(1, "time out");
if ((pfd[0].revents & (POLLERR|POLLNVAL)))
if (pfd[0].revents & (POLLERR|POLLNVAL))
errx(1, "bad fd %d", pfd[0].fd);
if ((pfd[0].revents & (POLLIN|POLLHUP))) {
if (pfd[0].revents & (POLLIN|POLLHUP)) {
if (read(STDIN_FILENO, buf, sizeof(buf)) == -1)
err(1, "read");
}