Author eryksun
Recipients carlkl, erik flister, eryksun, paul.moore, steve.dower, tim.golden, zach.ware
Date 2015-07-15.05:06:25
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1436936785.65.0.872809725738.issue24429@psf.upfronthosting.co.za>
In-reply-to
Content
> windll.python27._Py_ActivateActCtx would suffice 

It would instead be ctypes.pythonapi._Py_ActivateActCtx -- if the DLL exported a function with this name. ctypes.pythonapi is a PyDLL instance that wraps sys.dllhandle. 

I think it would be more useful in general to add an "actctx" parameter to CDLL. Then make PyWin_DLLhActivationContext public in PC/dl_nt.c, and add it as sys.dllactctx. Example usage:

    libc = CDLL('msvcr90', actctx=sys.dllactctx)

Along the lines of changing CDLL, it would also be nice to add a "flags" parameter and switch to using LoadLibraryEx. In comparison, POSIX users have easy access to the "mode" parameter (i.e. RTLD_LOCAL, RTLD_GLOBAL).
History
Date User Action Args
2015-07-15 05:06:25eryksunsetrecipients: + eryksun, paul.moore, tim.golden, zach.ware, steve.dower, carlkl, erik flister
2015-07-15 05:06:25eryksunsetmessageid: <1436936785.65.0.872809725738.issue24429@psf.upfronthosting.co.za>
2015-07-15 05:06:25eryksunlinkissue24429 messages
2015-07-15 05:06:25eryksuncreate