diff options
author | Claudio Jeker <claudio@cvs.openbsd.org> | 2023-07-11 12:14:17 +0000 |
---|---|---|
committer | Claudio Jeker <claudio@cvs.openbsd.org> | 2023-07-11 12:14:17 +0000 |
commit | 44b55af26f5f189363453a0877cfaf2378754ebb (patch) | |
tree | 190fb8641d3b01bb85c799751361ae54fe79cce8 /lib/libc/stdio | |
parent | ef1f2a7d07b70f1211102f52e64669a3372d2bf3 (diff) |
No need to initialize the first element of st->string since it was just
calloc(3)-ed a few lines above.
OK tb@
Diffstat (limited to 'lib/libc/stdio')
-rw-r--r-- | lib/libc/stdio/open_memstream.c | 3 | ||||
-rw-r--r-- | lib/libc/stdio/open_wmemstream.c | 3 |
2 files changed, 2 insertions, 4 deletions
diff --git a/lib/libc/stdio/open_memstream.c b/lib/libc/stdio/open_memstream.c index 7b063e37454..af0169f67f8 100644 --- a/lib/libc/stdio/open_memstream.c +++ b/lib/libc/stdio/open_memstream.c @@ -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; diff --git a/lib/libc/stdio/open_wmemstream.c b/lib/libc/stdio/open_wmemstream.c index 01dd782768d..fca0b7138c6 100644 --- a/lib/libc/stdio/open_wmemstream.c +++ b/lib/libc/stdio/open_wmemstream.c @@ -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; |