Moved all allocatable arrays to module mxsnWork. This allows the use of subroutine resetSNOPT that can check and deallocate all allocatable arrays, which can be registered with mexAtExit. Hopefully this prevents matlab crashes when unexpected errors occur.
Address issue #3.
Updated mexErrMsgTxt to mexErrMsgIdAndTxt.
Moved all allocatable arrays to module mxsnWork. This allows the use of subroutine resetSNOPT that can check and deallocate all allocatable arrays, which can be registered with mexAtExit. Hopefully this prevents matlab crashes when unexpected errors occur.