matlab_gs_error_string.c File Reference

#include <stdio.h>
#include <string.h>
#include <matrix.h>
#include <mex.h>
#include "grpc.h"
Include dependency graph for matlab_gs_error_string.c:

Go to the source code of this file.


void matlab_gs_error_string (int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[])

Detailed Description

Matlab client call

Definition in file matlab_gs_error_string.c.

Function Documentation

void matlab_gs_error_string ( int  nlhs,
mxArray *  plhs[],
int  nrhs,
const mxArray *  prhs[] 

Return the string representation of a error_code in the first right hand side argument (calling grpc_error_string).

nlhs - Number of left hand side arguments from Matlab
plhs - Pointer to left hand side arguments from Matlab
rlhs - Number of right hand side arguments from Matlab
plhs - Pointer to right hand side arguments from Matlab

Definition at line 29 of file matlab_gs_error_string.c.

  int i;
  grpc_error_t error_num;

  if ((nlhs != 1)||(nrhs != 2)) {
    mexErrMsgTxt("Usage: str = gs_error_string(error_code)\n");
    goto error;

  error_num = (grpc_error_t)(*mxGetPr(prhs[0]));
  plhs[0] = mxCreateString(grpc_error_string(error_num));


  for (i=0;i<nlhs;i++) plhs[i] = mxCreateDoubleMatrix(0,0,mxREAL); 
  mexPrintf("Warning: GridSolve call failed: %d:%d: %s; %s\n", grpc_errno, grpc_minor_errno, grpc_error_string(grpc_errno), grpc_minor_error_string(grpc_minor_errno));  


Here is the call graph for this function:

Here is the caller graph for this function: