wasmer/src/apis/emscripten/nullfunc.rs

53 lines
4.8 KiB
Rust
Raw Normal View History

2018-11-24 15:55:21 +01:00
use super::process::abort_with_message;
use crate::webassembly::Instance;
2018-11-26 20:28:13 -08:00
pub extern "C" fn nullfunc_ii(_x: u32, _instance: &Instance) {
2018-11-29 13:07:20 -08:00
debug!("emscripten::nullfunc_ii");
2018-11-24 15:55:21 +01:00
abort_with_message("Invalid function pointer called with signature 'ii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)");
}
2018-11-26 20:28:13 -08:00
pub extern "C" fn nullfunc_iii(_x: u32, _instance: &Instance) {
2018-11-29 13:07:20 -08:00
debug!("emscripten::nullfunc_iii");
2018-11-24 15:55:21 +01:00
abort_with_message("Invalid function pointer called with signature 'iii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)");
}
2018-11-26 20:28:13 -08:00
pub extern "C" fn nullfunc_iiii(_x: u32, _instance: &Instance) {
2018-11-29 13:07:20 -08:00
debug!("emscripten::nullfunc_iiii");
2018-11-24 15:55:21 +01:00
abort_with_message("Invalid function pointer called with signature 'iiii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)");
}
2018-11-26 20:28:13 -08:00
pub extern "C" fn nullfunc_iiiii(_x: u32, _instance: &Instance) {
2018-11-29 13:07:20 -08:00
debug!("emscripten::nullfunc_iiiii");
2018-11-24 15:55:21 +01:00
abort_with_message("Invalid function pointer called with signature 'iiiii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)");
}
2018-11-26 20:28:13 -08:00
pub extern "C" fn nullfunc_iiiiii(_x: u32, _instance: &Instance) {
2018-11-29 13:07:20 -08:00
debug!("emscripten::nullfunc_iiiiii");
2018-11-24 15:55:21 +01:00
abort_with_message("Invalid function pointer called with signature 'iiiiii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)");
2018-12-17 21:21:15 -06:00
}
pub extern "C" fn nullfunc_v(_x: u32, _instance: &Instance) {
debug!("emscripten::nullfunc_v");
abort_with_message("Invalid function pointer called with signature 'v'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)");
2018-11-24 15:55:21 +01:00
}
2018-11-26 20:28:13 -08:00
pub extern "C" fn nullfunc_vi(_x: u32, _instance: &Instance) {
2018-11-29 13:07:20 -08:00
debug!("emscripten::nullfunc_vi");
2018-11-24 15:55:21 +01:00
abort_with_message("Invalid function pointer called with signature 'vi'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)");
}
2018-11-26 20:28:13 -08:00
pub extern "C" fn nullfunc_vii(_x: u32, _instance: &Instance) {
2018-11-29 13:07:20 -08:00
debug!("emscripten::nullfunc_vii");
2018-11-24 15:55:21 +01:00
abort_with_message("Invalid function pointer called with signature 'vii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)");
}
2018-11-26 20:28:13 -08:00
pub extern "C" fn nullfunc_viii(_x: u32, _instance: &Instance) {
2018-11-29 13:07:20 -08:00
debug!("emscripten::nullfunc_viii");
2018-11-24 15:55:21 +01:00
abort_with_message("Invalid function pointer called with signature 'viii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)");
}
2018-11-26 20:28:13 -08:00
pub extern "C" fn nullfunc_viiii(_x: u32, _instance: &Instance) {
2018-11-29 13:07:20 -08:00
debug!("emscripten::nullfunc_viiii");
2018-11-24 15:55:21 +01:00
abort_with_message("Invalid function pointer called with signature 'viiii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)");
}