The C code base indicates errors using Return and Reason codes. The C code does not have any exception handling mechanism, as in C++. MQe does not use the operating system error handling functions. An MQeExceptBlock handles errors and returns values from the functions. An application is free to install any operating system exception handlers that it requires.
The specific nature of an error condition is returned using two values, MQERETURN and MQEREASON. MQERETURN determines the general area in which the application failed, and distinguishes between warnings and errors. You can ignore warnings, but you must not ignore errors. With errors, your application needs to solve the problem in order to continue safely.
MQERETURN and MQEREASON are both returned in the MQeExceptBlock. The MQERETURN value is also the return value from the function.