[issue24429] msvcrt error when embedded

Steve Dower report at bugs.python.org
Thu Jun 18 22:37:08 CEST 2015


Steve Dower added the comment:

> Steve, since you haven't closed this issue, have you considered my suggestion to export _Py_ActivateActCtx and _Py_DeactivateActCtx for use by C extensions such as _ctypes.pyd? These functions are better than manually creating a context from the manifest that's embedded in python27.dll because they use the context that was active when python27.dll was initially loaded.

I'm always fairly slow to close issues - don't read too much into that :)

I don't see any value in exporting them for other C extensions, since they can also capture the initial context when they are loaded. They really need exports for Python. windll.python27._Py_ActivateActCtx would suffice and I wouldn't want to go any further than that - this is *very* advanced functionality that I would expect most people to get wrong.

Someone prepare a patch. I'm not -1 yet (and of course, I'm not the sole gatekeeper here, so one of the core devs who's still working on 2.7 can fix it too).

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue24429>
_______________________________________


More information about the Python-bugs-list mailing list