On line 340 in the function mono_trace_set_printerr_handler in mono-4.0.2\mono\utils\mono-logger.c g_set_printerr_handler should be called instead of g_set_print_handler.
This is already fixed in mono master and the upcoming mono 4.2.
Doesn't seem that way to me. Looking at
I still see the same code:
mono_trace_set_printerr_handler (MonoPrintCallback callback)
printerr_callback = callback;
while g_set_print_handler should be g_set_printerr_handler.
The same is true about the mono-4.2.0-pre-branch and mono-4.2.0-pre2-branch.
Unless the latest changes have not yet been pushed to github.
Sorry about that, should be fixed now.