Ignore:
Timestamp:
Apr 5, 2010 9:30:27 AM (14 years ago)
Author:
dkearney
Message:

allow empty strings in matlab interface, error checking for empty strings should be done in the c/c++ core

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lang/matlab/RpMatlabInterface.cc

    r737 r1690  
    5555
    5656    /* Input must be a row vector. */
    57     if ( (mxGetM(prhs)) != 1)
     57    if ( (mxGetM(prhs) == 0) && (mxGetN(prhs) == 0)) {
     58        // do nothin, accept empty strings
     59    } else if ( (mxGetM(prhs)) != 1) {
    5860        mexErrMsgTxt("Input must be a row vector.");
     61    }
    5962
    6063    /* Get the length of the input string. */
Note: See TracChangeset for help on using the changeset viewer.