From 298a307a43a94bfd0af3e2f64f61d411f1bd1f69 Mon Sep 17 00:00:00 2001 From: Ilia K <ki.stfu@gmail.com> Date: Sat, 12 Oct 2019 13:41:12 +0300 Subject: [PATCH] Profiler API to modify environment variables (#23383) --- src/inc/corprof.idl | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/inc/corprof.idl b/src/inc/corprof.idl index 1d66137b10bc..18544f0bd9c0 100644 --- a/src/inc/corprof.idl +++ b/src/inc/corprof.idl @@ -3982,6 +3982,30 @@ interface ICorProfilerInfo10 : ICorProfilerInfo9 HRESULT ResumeRuntime(); } +[ + object, + uuid(DBCED7DD-C08F-4591-BCBF-0B6E4629030E), + pointer_default(unique), + local +] +interface ICorProfilerInfo11 : ICorProfilerInfo10 +{ + /* + * Set environment variable for the running managed code. + * + * The code profiler calls this function to modify environment variables of the + * current managed process. For example, it can be used in the profiler's Initialize() + * or InitializeForAttach() callbacks. + * + * szName is the name of the environment variable, should not be NULL. + * + * szValue is the contents of the environment variable, or NULL if the variable should be deleted. + */ + HRESULT SetEnvironmentVariable( + [in, string] const WCHAR *szName, + [in, string] const WCHAR *szValue); +} + /* * This interface lets you iterate over methods in the runtime. */