From 21a663ea2829b6808dd6981904c393332d271f8e Mon Sep 17 00:00:00 2001 From: Serhiy Storchaka Date: Wed, 13 Apr 2016 15:37:23 +0300 Subject: Issue #26057: Got rid of nonneeded use of PyUnicode_FromObject(). --- Python/bltinmodule.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'Python/bltinmodule.c') diff --git a/Python/bltinmodule.c b/Python/bltinmodule.c index 31d9e0e4d1..29fcffec61 100644 --- a/Python/bltinmodule.c +++ b/Python/bltinmodule.c @@ -1931,9 +1931,8 @@ builtin_input_impl(PyModuleDef *module, PyObject *prompt) Py_CLEAR(stringpo); if (po == NULL) goto _readline_errors; - promptstr = PyBytes_AsString(po); - if (promptstr == NULL) - goto _readline_errors; + assert(PyBytes_Check(po)); + promptstr = PyBytes_AS_STRING(po); } else { po = NULL; -- cgit v1.2.1