Commit d8052342 authored by Stéphane Adjemian's avatar Stéphane Adjemian
Browse files

Fixed bug introduced in cc0d9b42 (bytecode.cc).

Problem when reading nested structures.
parent f3334357
......@@ -707,10 +707,16 @@ main(int nrhs, const char *prhs[])
DYN_MEX_FUNC_ERR_MSG_TXT("verbosity is not a field of options_");
if (verbose)
print_it = true;
field = mxGetFieldNumber(options_, "simul.maxit");// Not sure of that...
if (field < 0)
DYN_MEX_FUNC_ERR_MSG_TXT("simul.maxit is not a field of options_");
int maxit_ = int (floor(*(mxGetPr(mxGetFieldByNumber(options_, 0, field)))));
field = mxGetFieldNumber(options_, "simul");
mxArray *simul;
if (field >= 0)
simul = mxGetFieldByNumber(options_, 0, field);
else
DYN_MEX_FUNC_ERR_MSG_TXT("simul is not a field of options_");
field = mxGetFieldNumber(simul, "maxit");
if (field<0)
DYN_MEX_FUNC_ERR_MSG_TXT("maxit is not a field of options_.simul");
int maxit_ = int (floor(*(mxGetPr(mxGetFieldByNumber(simul, 0, field)))));
field = mxGetFieldNumber(options_, "slowc");
if (field < 0)
DYN_MEX_FUNC_ERR_MSG_TXT("slows is not a field of options_");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment