Changeset 7734
- Timestamp:
- 03/31/11 14:09:49 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk/src/mex/KMLMeshWrite/KMLMeshWrite.cpp
r7661 r7734 13 13 char* notes=NULL; 14 14 const mxArray* notesi; 15 mwSize nsize;16 15 mwIndex nindex; 17 16 … … 42 41 43 42 FILE* fid=NULL; 43 44 DataSet* options=NULL; 44 45 45 46 /* output: */ … … 52 53 if (nlhs > NLHS) { 53 54 KMLMeshWriteUsage(); 54 _error_("KMLMeshWrite Usageusage error");55 } 56 if (nrhs !=NRHS) {55 _error_("KMLMeshWrite usage error"); 56 } 57 if (nrhs < NRHS) { 57 58 KMLMeshWriteUsage(); 58 _error_("KMLMeshWrite Usageusage error");59 _error_("KMLMeshWrite usage error"); 59 60 } 60 61 … … 66 67 /* notes is typically a cell array of character strings */ 67 68 if (mxIsCell(NOTES)) { 68 nsize=mxGetNumberOfElements(NOTES); 69 for (nindex=0; nindex<nsize; nindex++) { 69 for (nindex=0; nindex<mxGetNumberOfElements(NOTES); nindex++) { 70 70 notesi=mxGetCell(NOTES,nindex); 71 71 if (notesi && mxIsChar(notesi) && mxGetNumberOfElements(notesi)) { … … 107 107 if (verbose) printf(" filnam =\"%s\"\n",filnam); 108 108 109 if (nrhs > NRHS) { 110 if (verbose) printf("Parsing options:\n"); 111 options=OptionsParse(NRHS,nrhs,prhs); 112 } 113 109 114 /*some checks*/ 110 115 if (verbose) printf("Checking inputs:\n"); … … 158 163 WriteData(ERRORFLAG,ierror); 159 164 165 if (options) { 166 delete options; 167 options=NULL; 168 } 169 160 170 if (mxIsCell(NOTES) && notes) 161 171 xfree((void**)¬es); … … 191 201 _printf_(true,"\n"); 192 202 } 203
Note:
See TracChangeset
for help on using the changeset viewer.