Commit 7d7fa9d
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 2eb7ed5 commit 7d7fa9d
2 files changed
Lines changed: 36 additions & 8 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 | |
|---|---|---|---|
| |||
185 | 185 | | |
186 | 186 | | |
187 | 187 | | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
188 | 196 | | |
189 | 197 | | |
190 | 198 | | |
| |||
1839 | 1847 | | |
1840 | 1848 | | |
1841 | 1849 | | |
1842 | | - | |
| 1850 | + | |
1843 | 1851 | | |
1844 | | - | |
| 1852 | + | |
1845 | 1853 | | |
1846 | 1854 | | |
1847 | 1855 | | |
1848 | | - | |
| 1856 | + | |
1849 | 1857 | | |
1850 | 1858 | | |
1851 | 1859 | | |
| |||
1854 | 1862 | | |
1855 | 1863 | | |
1856 | 1864 | | |
1857 | | - | |
| 1865 | + | |
1858 | 1866 | | |
1859 | 1867 | | |
1860 | 1868 | | |
1861 | 1869 | | |
1862 | | - | |
| 1870 | + | |
| 1871 | + | |
1863 | 1872 | | |
1864 | 1873 | | |
1865 | 1874 | | |
| |||
1868 | 1877 | | |
1869 | 1878 | | |
1870 | 1879 | | |
1871 | | - | |
| 1880 | + | |
| 1881 | + | |
1872 | 1882 | | |
1873 | 1883 | | |
1874 | 1884 | | |
1875 | 1885 | | |
1876 | 1886 | | |
| 1887 | + | |
| 1888 | + | |
| 1889 | + | |
| 1890 | + | |
| 1891 | + | |
| 1892 | + | |
| 1893 | + | |
| 1894 | + | |
| 1895 | + | |
| 1896 | + | |
| 1897 | + | |
| 1898 | + | |
| 1899 | + | |
| 1900 | + | |
| 1901 | + | |
1877 | 1902 | | |
1878 | | - | |
1879 | | - | |
| 1903 | + | |
| 1904 | + | |
1880 | 1905 | | |
1881 | 1906 | | |
1882 | 1907 | | |
| |||
0 commit comments