Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[wasm] Use g_printerr to emit errors in mini-wasm.c, so they show up wit… #49838

Merged
merged 3 commits into from
Mar 20, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/mono/mono/mini/mini-wasm.c
Original file line number Diff line number Diff line change
Expand Up @@ -567,13 +567,13 @@ mono_set_timeout_exec (int id)
//YES we swallow exceptions cuz there's nothing much we can do from here.
//FIXME Maybe call the unhandled exception function?
if (!is_ok (error)) {
printf ("timeout callback failed due to %s\n", mono_error_get_message (error));
g_printerr ("timeout callback failed due to %s\n", mono_error_get_message (error));
mono_error_cleanup (error);
}

if (exc) {
char *type_name = mono_type_get_full_name (mono_object_class (exc));
printf ("timeout callback threw a %s\n", type_name);
g_printerr ("timeout callback threw a %s\n", type_name);
g_free (type_name);
}
}
Expand Down Expand Up @@ -605,13 +605,13 @@ tp_cb (void)
mono_runtime_try_invoke (method, NULL, NULL, &exc, error);

if (!is_ok (error)) {
printf ("ThreadPool Callback failed due to error: %s\n", mono_error_get_message (error));
g_printerr ("ThreadPool Callback failed due to error: %s\n", mono_error_get_message (error));
mono_error_cleanup (error);
}

if (exc) {
char *type_name = mono_type_get_full_name (mono_object_class (exc));
printf ("ThreadPool Callback threw an unhandled exception of type %s\n", type_name);
g_printerr ("ThreadPool Callback threw an unhandled exception of type %s\n", type_name);
g_free (type_name);
}
}
Expand Down