mirror of
https://github.com/python/cpython.git
synced 2025-08-30 13:38:43 +00:00
bpo-32241: Add the const qualifire to declarations of umodifiable strings. (#4748)
This commit is contained in:
parent
5ce0a2a100
commit
4ae06c5337
15 changed files with 59 additions and 56 deletions
|
@ -100,7 +100,7 @@ static PyObject *
|
|||
sys_breakpointhook(PyObject *self, PyObject **args, Py_ssize_t nargs, PyObject *keywords)
|
||||
{
|
||||
assert(!PyErr_Occurred());
|
||||
char *envar = Py_GETENV("PYTHONBREAKPOINT");
|
||||
const char *envar = Py_GETENV("PYTHONBREAKPOINT");
|
||||
|
||||
if (envar == NULL || strlen(envar) == 0) {
|
||||
envar = "pdb.set_trace";
|
||||
|
@ -109,8 +109,8 @@ sys_breakpointhook(PyObject *self, PyObject **args, Py_ssize_t nargs, PyObject *
|
|||
/* The breakpoint is explicitly no-op'd. */
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
char *last_dot = strrchr(envar, '.');
|
||||
char *attrname = NULL;
|
||||
const char *last_dot = strrchr(envar, '.');
|
||||
const char *attrname = NULL;
|
||||
PyObject *modulepath = NULL;
|
||||
|
||||
if (last_dot == NULL) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue