Commit f6b1201
authored
Passing n to the library is ncurses' reading of n: it stores n characters
and adds a terminator. NetBSD curses counts the terminator in n.
Ask a library that is neither ncurses nor PDCurses for n + 1, and read
again if it stored more than asked; truncating could split a multibyte
character. This is not possible for input, so getstr() is left as it is.
instr() now takes the length from the value returned by winnstr(), as
X/Open specifies, instead of searching for a terminator which it does not.
(cherry picked from commit 43a1869)
1 parent 9b7eb47 commit f6b1201
2 files changed
Lines changed: 26 additions & 7 deletions
File tree
- Misc/NEWS.d/next/Library
- Modules
Lines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
215 | 215 | | |
216 | 216 | | |
217 | 217 | | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
218 | 226 | | |
219 | 227 | | |
220 | 228 | | |
| |||
2014 | 2022 | | |
2015 | 2023 | | |
2016 | 2024 | | |
2017 | | - | |
| 2025 | + | |
| 2026 | + | |
2018 | 2027 | | |
2019 | 2028 | | |
2020 | 2029 | | |
2021 | 2030 | | |
2022 | 2031 | | |
2023 | 2032 | | |
2024 | | - | |
2025 | | - | |
2026 | | - | |
2027 | | - | |
2028 | | - | |
| 2033 | + | |
| 2034 | + | |
| 2035 | + | |
| 2036 | + | |
| 2037 | + | |
| 2038 | + | |
| 2039 | + | |
| 2040 | + | |
| 2041 | + | |
| 2042 | + | |
| 2043 | + | |
| 2044 | + | |
2029 | 2045 | | |
2030 | 2046 | | |
2031 | 2047 | | |
2032 | 2048 | | |
2033 | 2049 | | |
2034 | 2050 | | |
2035 | | - | |
| 2051 | + | |
2036 | 2052 | | |
2037 | 2053 | | |
2038 | 2054 | | |
| |||
0 commit comments