Changeset 13173
- Timestamp:
- 08/28/12 14:49:23 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/modules/KMLMeshWrite/KMLMeshWrite.cpp
r13038 r13173 11 11 char* name=NULL; 12 12 char* notes=NULL; 13 char* notes2=NULL; 13 14 const mxArray* notesi; 14 15 mwIndex nindex; … … 60 61 else { 61 62 /* note that strlen does not include trailing null */ 62 notes=(char*)xrealloc(notes,(strlen(notes)+1+mxGetNumberOfElements(notesi)+1)*sizeof(char)); 63 notes2=xNew<char>(strlen(notes)+1+mxGetNumberOfElements(notesi)+1); 64 memcpy(notes2,notes,(strlen(notes)+1)*sizeof(char)); 65 xDelete<char>(notes); 66 notes=notes2; 67 notes2=NULL; 68 // notes=(char*)xrealloc(notes,(strlen(notes)+1+mxGetNumberOfElements(notesi)+1)*sizeof(char)); 63 69 strcat(notes,"\n"); 64 70 mxGetString(notesi,¬es[strlen(notes)],mxGetNumberOfElements(notesi)+1);
Note:
See TracChangeset
for help on using the changeset viewer.