MLClearError()

MLClearError has been replaced by WSClearError.

int MLClearError(MLINK link)

clears errors on if possible.

Details

  • MLClearError() will activate a previously unactivated link.
  • MLClearError() will return 0 for certain catastrophic errors such as MLEDEAD that indicates that the link has closed unexpectedly.
  • MLClearError() returns a nonzero value on successful completion.
  • MLClearError() is declared in the MathLink header file mathlink.h.

Examples

Basic Examples  (1)

#include <stdio.h>
#include "mathlink.h"

/* send an integer to a link and check for an error */

void f(MLINK lp)
{
    if(! MLPutInteger(lp, 10))
    {
        printf("MathLink error: %s\n", MLErrorMessage(lp));
        MLClearError(lp);
    }
}

See Also

MLError()  MLErrorMessage()

Tutorials