RETURN_ERROR |
RETURN_ERROR( errno )
Sets the error condition to errno using mb_set_error and return with a MB_FUNC_ERR return status.
Example
///////////////////////////////////////////////////////////////////////////// // // status = VIDEO.Play( nControl AS INTEGER, // direction AS INTEGER ) AS INTEGER // ///////////////////////////////////////////////////////////////////////////// // int _MaxTRAQX_Play( mb_interpreter_t* s, void** l ) { AFX_MANAGE_STATE( AfxGetStaticModuleState() ); //////////////////////////////////////////////////////////////////////////
BEGIN_PARSE( s, l ) POP_INT( nControl ) OPT_INT( nDirection, 0 ) END_PARSE
if ( !SKIPPED_LAST ) { if ( g_this->SetPlay( nControl, nDirection ) < 0 ) { RETURN_ERROR( SE_RN_INVALID_ARGUMENT ); } endif } endif
int nRet = g_this->GetPlay( nControl );
RETURN_INT( nRet ); } endfunc
|