summaryrefslogtreecommitdiff
path: root/Modules/_cursesmodule.c
AgeCommit message (Collapse)AuthorLines
2018-11-27bpo-33012: Fix signatures of METH_NOARGS functions. (GH-10736) (GH-10748)Miss Islington (bot)-6/+6
(cherry picked from commit 81524022d0c0df7a41f9b2b2df41e2ebe140e610) (cherry picked from commit ad8ac54aa3d2323bdb5feb5e858a922840358187) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2018-11-27[3.6] bpo-33029: Fix signatures of getter and setter functions. (GH-10746) ↵Serhiy Storchaka-1/+1
(GH-10749) Fix also return type for few other functions (clear, releasebuffer). (cherry picked from commit d4f9cf5545d6d8844e0726552ef2e366f5cc3abd)
2017-12-21correct the typos (GH-4950) (#4951)Miss Islington (bot)-2/+2
(cherry picked from commit 83cb778b4a3f856f2243b0f0d36fefb5c44b388f)
2017-11-01bpo-27666: Fixed stack corruption in curses.box() and curses.ungetmouse(). ↵Miss Islington (bot)-12/+26
(GH-4220) (#4221) (cherry picked from commit 4f469c096628af730b17798d0ebfd8925bfde836)
2017-11-01bpo-15037: Add a workaround for getkey() in curses for ncurses 5.7 and ↵Miss Islington (bot)-2/+10
earlier. (GH-3826) (#4218) Skip a test for unget_wch()/get_wch() on OpenBSD since they are broken in ncurses 5.7. (cherry picked from commit 7e68790f3db75a893d5dd336e6201a63bc70212b)
2017-11-01bpo-31919: Fix building the curses module on OpenIndiana. (GH-4211) (#4215)Miss Islington (bot)-2/+4
(cherry picked from commit 894ebd065e02debf20c0657d26020ecc42b7534f)
2017-11-01bpo-25720: Fix the method for checking pad state of curses WINDOW (GH-4164) ↵Miss Islington (bot)-8/+16
(#4212) Modify the code to use ncurses is_pad() instead of checking WINDOW _flags field. If your platform does not provide the is_pad(), the existing way that checks the field will be enabled. Note: This change does not drop support for platforms where do not have both WINDOW _flags field and is_pad(). (cherry picked from commit 8bc7d63560024681dce9f40445f2877b2987e92c)
2017-10-31bpo-31891: Fix building the curses module on NetBSD. (GH-4165) (#4189)Miss Islington (bot)-33/+40
(cherry picked from commit baac01e629d90f63dfde6b5cc433f4bc65c5feeb)
2017-06-28[3.6] bpo-13617: Reject embedded null characters in wchar* strings. ↵Serhiy Storchaka-0/+9
(GH-2302) (#2462) Based on patch by Victor Stinner. Add private C API function _PyUnicode_AsUnicode() which is similar to PyUnicode_AsUnicode(), but checks for null characters.. (cherry picked from commit f7eae0adfcd4c50034281b2c69f461b43b68db84)
2017-06-27[3.6] bpo-30708: Check for null characters in PyUnicode_AsWideCharString(). ↵Serhiy Storchaka-1/+1
(GH-2285) (#2443) Raise a ValueError if the second argument is NULL and the wchar_t\* string contains null characters.. (cherry picked from commit e613e6add5f07ff6aad5802924596b631b707d2a)
2017-03-08bpo-29176: Fix name of the _curses.window class (#52) (#532)Mariatta-1/+1
Set name to "_curses.window" instead of "_curses.curses window" (with a space!?). (cherry picked from commit 61e2bc74dfab1ceee332d3f480dcf86c478c87c5)
2016-10-30Issue #28549: Fixed segfault in curses's addch() with ncurses6.Serhiy Storchaka-8/+9
2016-10-30Issue #28549: Fixed segfault in curses's addch() with ncurses6.Serhiy Storchaka-8/+9
2016-10-27Issue #28526: Use PyUnicode_AsEncodedString() instead ofSerhiy Storchaka-2/+2
PyUnicode_AsEncodedObject() in _curese to ensure that the result is a bytes object.
2016-10-27Issue #28526: Use PyUnicode_AsEncodedString() instead ofSerhiy Storchaka-2/+2
PyUnicode_AsEncodedObject() in _curese to ensure that the result is a bytes object.
2016-09-05Avoid calling functions with an empty string as format stringVictor Stinner-1/+1
Directly pass NULL rather than an empty string.
2016-08-15merge 3.4Benjamin Peterson-0/+8
2016-08-15fail when negative values are passed to instr()Benjamin Peterson-0/+8
2016-08-13merge 3.4Benjamin Peterson-0/+8
2016-08-13do not allow reading negative values with getstr()Benjamin Peterson-0/+8
2014-05-04Issue #21088: Bugfix for curses.window.addch() regression in 3.4.0.Larry Hastings-12/+12
In porting to Argument Clinic, the first two arguments were reversed.
2014-01-31#Issue 20456: Several improvements and bugfixes for Argument Clinic,Larry Hastings-2/+2
including correctly generating code for Clinic blocks inside C preprocessor conditional blocks.
2014-01-28Issue #20326: Argument Clinic now uses a simple, unique signature toLarry Hastings-2/+2
annotate text signatures in docstrings, resulting in fewer false positives. "self" parameters are also explicitly marked, allowing inspect.Signature() to authoritatively detect (and skip) said parameters. Issue #20326: Argument Clinic now generates separate checksums for the input and output sections of the block, allowing external tools to verify that the input has not changed (and thus the output is not out-of-date).
2014-01-25Issue #20390: Small fixes and improvements for Argument Clinic.Larry Hastings-5/+5
2014-01-24Issue #20189: Four additional builtin types (PyTypeObject,Larry Hastings-2/+2
PyMethodDescr_Type, _PyMethodWrapper_Type, and PyWrapperDescr_Type) have been modified to provide introspection information for builtins. Also: many additional Lib, test suite, and Argument Clinic fixes.
2014-01-22Two minor Argument Clinic bugfixes: use the name of the class in theLarry Hastings-6/+7
docstring for __new__ and __init__, and always use "goto exit" instead of returning "NULL" for failure to parse (as _new__ and __init__ return ints).
2014-01-20Issue #20315: Removed support for backward compatibility with early 2.x ↵Serhiy Storchaka-2/+0
versions. Removed backward compatibility alias curses.window.nooutrefresh which should be removed in 2.3.
2014-01-16Issue #20226: Major improvements to Argument Clinic.Larry Hastings-2/+2
* You may now specify an expression as the default value for a parameter! Example: "sys.maxsize - 1". This support is intentionally quite limited; you may only use values that can be represented as static C values. * Removed "doc_default", simplified support for "c_default" and "py_default". (I'm not sure we still even need "py_default", but I'm leaving it in for now in case a use presents itself.) * Parameter lines support a trailing '\\' as a line continuation character, allowing you to break up long lines. * The argument parsing code generated when supporting optional groups now uses PyTuple_GET_SIZE instead of PyTuple_GetSize, leading to a 850% speedup in parsing. (Just kidding, this is an unmeasurable difference.) * A bugfix for the recent regression where the generated prototype from pydoc for builtins would be littered with unreadable "=<object ...>"" default values for parameters that had no default value. * Converted some asserts into proper failure messages. * Many doc improvements and fixes.
2014-01-07Issue #19273: The marker comments Argument Clinic uses have been changedLarry Hastings-6/+6
to improve readability.
2013-12-04ncurses' winch and mvwinch return an unsigned longChristian Heimes-2/+3
2013-12-04ncurses' winch and mvwinch return an unsigned longChristian Heimes-2/+3
2013-11-23Issue #19674: inspect.signature() now produces a correct signatureLarry Hastings-4/+8
for some builtins.
2013-11-20Issue #19474: Argument Clinic now always specifies a default value forLarry Hastings-4/+4
variables in option groups, to prevent "uninitialized value" warnings.
2013-11-18Argument Clinic: rename "self" to "module" for module-level functions.Larry Hastings-1/+0
2013-11-07Issue #19512, #19515: remove shared identifiers, move identifiers where theyVictor Stinner-1/+1
are used. Move also _Py_IDENTIFIER() defintions to the top in modified files to remove identifiers duplicated in the same file.
2013-11-06Issue #19512: add some common identifiers to only create common strings once,Victor Stinner-1/+1
instead of creating temporary Unicode string objects Add also more identifiers in pythonrun.c to avoid temporary Unicode string objets for the interactive interpreter.
2013-10-19Fix compilation of the curses module (broken by issue #16612).Serhiy Storchaka-1/+1
2013-10-19Issue #16612: Add "Argument Clinic", a compile-time preprocessorLarry Hastings-41/+114
for C files to generate argument parsing code. (See PEP 436.)
2013-08-28Issue #18571: Implementation of the PEP 446: file descriptors and file handlesVictor Stinner-32/+39
are now created non-inheritable; add functions os.get/set_inheritable(), os.get/set_handle_inheritable() and socket.socket.get/set_inheritable().
2013-07-26Fix possible NULL pointer dereference in PyCurses_Start_Color()Christian Heimes-0/+4
CID 1058276
2013-07-26Fix possible NULL pointer dereference in PyCurses_Start_Color()Christian Heimes-0/+4
CID 1058276
2013-07-07Issue #18203: Add _PyMem_RawStrdup() and _PyMem_Strdup()Victor Stinner-4/+4
Replace strdup() with _PyMem_RawStrdup() or _PyMem_Strdup(), depending if the GIL is held or not.
2013-07-07Issue #18203: Replace malloc() with PyMem_Malloc() in Python modulesVictor Stinner-2/+2
Replace malloc() with PyMem_Malloc() when the GIL is held, or with PyMem_RawMalloc() otherwise.
2013-06-04Reuse Py_MIN and Py_MAX macros: remove duplicate MIN/MAX macrosVictor Stinner-9/+5
multiprocessing.h: remove unused MIN and MAX macros
2013-05-16C89 declaration complianceBenjamin Peterson-1/+1
2013-03-21Issue #17209: curses.window.get_wch() now handles correctly ↵Victor Stinner-0/+3
KeyboardInterrupt (CTRL+c)
2013-03-19Merge: #8862: Fix curses cleanup with getchar is interrupted by a signal.R David Murray-1/+3
I have no idea how one would write a test for this. Patch by July Tikhonov.
2013-03-19#8862: Fix curses cleanup with getchar is interrupted by a signal.R David Murray-1/+3
I have no idea how one would write a test for this. Patch by July Tikhonov.
2012-09-07Issue #15876: Fix a refleak in the curses moduleRoss Lagerwall-0/+1
The refleak occurred when assigning to window.encoding.
2012-09-01Close #14223: Fix window.addch(curses.ACS_HLINE)Victor Stinner-27/+7
Fix window.addch() of the curses module for special characters like curses.ACS_HLINE: the Python function addch(int) and addch(bytes) is now calling the C function waddch()/mvwaddch() (as it was done in Python 3.2), instead of wadd_wch()/mvwadd_wch(). The Python function addch(str) is still calling the C function wadd_wch()/mvwadd_wch() if the Python curses is linked to libncursesw.