forked from hyperlight-dev/hyperlight
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathguest_error.fbs
27 lines (24 loc) · 1.86 KB
/
guest_error.fbs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
namespace Hyperlight.Generated;
enum ErrorCode: ulong {
NoError = 0, // The function call was successful
UnsupportedParameterType = 2, // The type of the parameter is not supported by the Guest.
GuestFunctionNameNotProvided = 3, // The Guest function name was not provided by the host.
GuestFunctionNotFound = 4, // The function does not exist in the Guest.
GuestFunctionIncorrecNoOfParameters = 5, // Incorrect number of parameters for the guest function.
GispatchFunctionPointerNotSet = 6, // Host Call Dispatch Function Pointer is not present.
OutbError = 7, // Error in OutB Function
UnknownError = 8, // The guest error is unknown.
StackOverflow = 9, // Guest stack allocations caused stack overflow
GsCheckFailed = 10, // __security_check_cookie failed
TooManyGuestFunctions = 11, // The guest tried to register too many guest functions
FailureInDlmalloc = 12, // this error is set when dlmalloc calls ABORT (e.g. function defined in ABORT (dlmalloc_abort() calls setError with this errorcode)
MallocFailed = 13, // this error is set when malloc returns 0 bytes.
GuestFunctionParameterTypeMismatch = 14, // The function call parameter type was not the expected type.
GuestError = 15, // An error occurred in the guest Guest implementation should use this along with a message when calling setError.
ArrayLengthParamIsMissing = 16 // Expected a int parameter to follow a byte array
}
table GuestError {
code: ErrorCode;
message: string;
}
root_type GuestError;