From 9e87e7776f7ace66baaf7247233afdabd00c2b44 Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Fri, 24 Nov 2017 12:09:24 +0100 Subject: bpo-32096: Remove obj and mem from _PyRuntime (#4532) bpo-32096, bpo-30860: Partially revert the commit 2ebc5ce42a8a9e047e790aefbf9a94811569b2b6: * Move structures back from Include/internal/mem.h to Objects/obmalloc.c * Remove _PyObject_Initialize() and _PyMem_Initialize() * Remove Include/internal/pymalloc.h * Add test_capi.test_pre_initialization_api(): Make sure that it's possible to call Py_DecodeLocale(), and then call Py_SetProgramName() with the decoded string, before Py_Initialize(). PyMem_RawMalloc() and Py_DecodeLocale() can be called again before _PyRuntimeState_Init(). Co-Authored-By: Eric Snow --- Python/pystate.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'Python/pystate.c') diff --git a/Python/pystate.c b/Python/pystate.c index f6fbb4d041..ecf921d0c2 100644 --- a/Python/pystate.c +++ b/Python/pystate.c @@ -40,8 +40,6 @@ _PyRuntimeState_Init(_PyRuntimeState *runtime) { memset(runtime, 0, sizeof(*runtime)); - _PyObject_Initialize(&runtime->obj); - _PyMem_Initialize(&runtime->mem); _PyGC_Initialize(&runtime->gc); _PyEval_Initialize(&runtime->ceval); -- cgit v1.2.1