summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Belopolsky <alexander.belopolsky@gmail.com>2015-09-28 02:13:28 (GMT)
committerAlexander Belopolsky <alexander.belopolsky@gmail.com>2015-09-28 02:13:28 (GMT)
commit5d27ed858ae9e4819884c9526b2e3bff516d9289 (patch)
tree62f3db2401e67a8236c9150b3b3ea120888ec8a7
parentd19b5042ff9203a050676746d6723566e0a75812 (diff)
parenta6c5d53eec87028ba3b68e9b471a9215b2e1bc85 (diff)
downloadcpython-5d27ed858ae9e4819884c9526b2e3bff516d9289.zip
cpython-5d27ed858ae9e4819884c9526b2e3bff516d9289.tar.gz
cpython-5d27ed858ae9e4819884c9526b2e3bff516d9289.tar.bz2
merge
-rw-r--r--Misc/NEWS6
-rw-r--r--Modules/readline.c9
2 files changed, 11 insertions, 4 deletions
diff --git a/Misc/NEWS b/Misc/NEWS
index 5d68a94..6c93caf 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -27,6 +27,12 @@ Core and Builtins
Library
-------
+- Issue #23600: Default implementation of tzinfo.fromutc() was returning
+ wrong results in some cases.
+
+- Issue #25203: Failed readline.set_completer_delims() no longer left the
+ module in inconsistent state.
+
- Issue #25011: rlcomplete now omits private and special attribute names unless
the prefix starts with underscores.
diff --git a/Modules/readline.c b/Modules/readline.c
index 09877f2..451a6ed 100644
--- a/Modules/readline.c
+++ b/Modules/readline.c
@@ -464,10 +464,11 @@ set_completer_delims(PyObject *self, PyObject *args)
/* Keep a reference to the allocated memory in the module state in case
some other module modifies rl_completer_word_break_characters
(see issue #17289). */
- free(completer_word_break_characters);
- completer_word_break_characters = strdup(break_chars);
- if (completer_word_break_characters) {
- rl_completer_word_break_characters = completer_word_break_characters;
+ break_chars = strdup(break_chars);
+ if (break_chars) {
+ free(completer_word_break_characters);
+ completer_word_break_characters = break_chars;
+ rl_completer_word_break_characters = break_chars;
Py_RETURN_NONE;
}
else