Commit ad5c4671 authored by Vincent Povirk's avatar Vincent Povirk Committed by Alexandre Julliard

mscoree: Add WINE_MONO_VERBOSE environment setting.

parent c0a17a4f
...@@ -138,6 +138,8 @@ static HRESULT load_mono(CLRRuntimeInfo *This, loaded_mono **result) ...@@ -138,6 +138,8 @@ static HRESULT load_mono(CLRRuntimeInfo *This, loaded_mono **result)
char mono_lib_path_a[MAX_PATH], mono_etc_path_a[MAX_PATH]; char mono_lib_path_a[MAX_PATH], mono_etc_path_a[MAX_PATH];
int trace_size; int trace_size;
char trace_setting[256]; char trace_setting[256];
int verbose_size;
char verbose_setting[256];
if (This->mono_abi_version <= 0 || This->mono_abi_version > NUM_ABI_VERSIONS) if (This->mono_abi_version <= 0 || This->mono_abi_version > NUM_ABI_VERSIONS)
{ {
...@@ -204,6 +206,7 @@ static HRESULT load_mono(CLRRuntimeInfo *This, loaded_mono **result) ...@@ -204,6 +206,7 @@ static HRESULT load_mono(CLRRuntimeInfo *This, loaded_mono **result)
LOAD_MONO_FUNCTION(mono_runtime_object_init); LOAD_MONO_FUNCTION(mono_runtime_object_init);
LOAD_MONO_FUNCTION(mono_runtime_quit); LOAD_MONO_FUNCTION(mono_runtime_quit);
LOAD_MONO_FUNCTION(mono_set_dirs); LOAD_MONO_FUNCTION(mono_set_dirs);
LOAD_MONO_FUNCTION(mono_set_verbose_level);
LOAD_MONO_FUNCTION(mono_stringify_assembly_name); LOAD_MONO_FUNCTION(mono_stringify_assembly_name);
LOAD_MONO_FUNCTION(mono_string_new); LOAD_MONO_FUNCTION(mono_string_new);
LOAD_MONO_FUNCTION(mono_thread_attach); LOAD_MONO_FUNCTION(mono_thread_attach);
...@@ -254,6 +257,13 @@ static HRESULT load_mono(CLRRuntimeInfo *This, loaded_mono **result) ...@@ -254,6 +257,13 @@ static HRESULT load_mono(CLRRuntimeInfo *This, loaded_mono **result)
{ {
(*result)->mono_jit_set_trace_options(trace_setting); (*result)->mono_jit_set_trace_options(trace_setting);
} }
verbose_size = GetEnvironmentVariableA("WINE_MONO_VERBOSE", verbose_setting, sizeof(verbose_setting));
if (verbose_size)
{
(*result)->mono_set_verbose_level(verbose_setting[0] - '0');
}
} }
return S_OK; return S_OK;
......
...@@ -171,6 +171,7 @@ struct loaded_mono ...@@ -171,6 +171,7 @@ struct loaded_mono
void (CDECL *mono_runtime_quit)(void); void (CDECL *mono_runtime_quit)(void);
void (CDECL *mono_runtime_set_shutting_down)(void); void (CDECL *mono_runtime_set_shutting_down)(void);
void (CDECL *mono_set_dirs)(const char *assembly_dir, const char *config_dir); void (CDECL *mono_set_dirs)(const char *assembly_dir, const char *config_dir);
void (CDECL *mono_set_verbose_level)(DWORD level);
char* (CDECL *mono_stringify_assembly_name)(MonoAssemblyName *aname); char* (CDECL *mono_stringify_assembly_name)(MonoAssemblyName *aname);
void (CDECL *mono_thread_pool_cleanup)(void); void (CDECL *mono_thread_pool_cleanup)(void);
void (CDECL *mono_thread_suspend_all_other_threads)(void); void (CDECL *mono_thread_suspend_all_other_threads)(void);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment