diff options
author | Riccardo Spagni <ric@spagni.net> | 2015-05-31 16:36:48 +0200 |
---|---|---|
committer | Riccardo Spagni <ric@spagni.net> | 2015-05-31 16:36:48 +0200 |
commit | 6a1190792b0409e7a996400614e5e2c6ba02e5f6 (patch) | |
tree | fa324d2f9f02668a6d56d2e4d195a59ab1d3710e /external/unbound/pythonmod/pythonmod.c | |
parent | fixed static assert test (diff) | |
download | monero-6a1190792b0409e7a996400614e5e2c6ba02e5f6.tar.xz |
update libunbound
Diffstat (limited to 'external/unbound/pythonmod/pythonmod.c')
-rw-r--r-- | external/unbound/pythonmod/pythonmod.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/external/unbound/pythonmod/pythonmod.c b/external/unbound/pythonmod/pythonmod.c index 190d41a81..48dbc0169 100644 --- a/external/unbound/pythonmod/pythonmod.c +++ b/external/unbound/pythonmod/pythonmod.c @@ -133,7 +133,13 @@ int pythonmod_init(struct module_env* env, int id) /* Initialize Python libraries */ if (!Py_IsInitialized()) { - Py_SetProgramName("unbound"); +#if PY_MAJOR_VERSION >= 3 + wchar_t progname[8]; + mbstowcs(progname, "unbound", 8); +#else + char *progname = "unbound"; +#endif + Py_SetProgramName(progname); Py_NoSiteFlag = 1; Py_Initialize(); PyEval_InitThreads(); |