From: Jorge Pereira Date: Tue, 17 Sep 2019 20:49:13 +0000 (-0300) Subject: rlm_python: Fix the wide_path changes made in 1eb569dcb4 (#2998) X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=45a0784c045809beb21b68f318f69581490efd2f;p=thirdparty%2Ffreeradius-server.git rlm_python: Fix the wide_path changes made in 1eb569dcb4 (#2998) --- diff --git a/src/modules/rlm_python/rlm_python.c b/src/modules/rlm_python/rlm_python.c index 72d39648f0a..5f0e7e77129 100644 --- a/src/modules/rlm_python/rlm_python.c +++ b/src/modules/rlm_python/rlm_python.c @@ -63,12 +63,6 @@ typedef struct { ///< rlm_python module config in the python path. bool python_path_include_default; //!< Include the default python path ///< in the python path. - -#if PY_MAJOR_VERSION == 3 - wchar_t *wide_path; //!< Special wide char encoding of radiusd path. - //!< FreeRADIUS functions. -#endif - PyObject *module; //!< Local, interpreter specific module. #if PY_MAJOR_VERSION == 2 @@ -961,8 +955,8 @@ static int python_interpreter_init(rlm_python_t *inst, CONF_SECTION *conf) DEBUG3("Setting python path to \"%s\"", path); wide_path = Py_DecodeLocale(path, NULL); talloc_free(path); - PySys_SetPath(inst->wide_path); - PyMem_RawFree(inst->wide_path); + PySys_SetPath(wide_path); + PyMem_RawFree(wide_path); /* * Import the radiusd module into this python