Changeset 1234
- Timestamp:
- 15/04/09 10:39:54 (3 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
-
applications/nxconvert_common.c (modified) (2 diffs)
-
src/nxdataset.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/applications/nxconvert_common.c
r1079 r1234 94 94 return NX_ERROR; 95 95 } 96 96 97 97 /* Output global attributes */ 98 98 if (WriteAttributes (nx_is_definition) != NX_OK) … … 105 105 return NX_ERROR; 106 106 } 107 /* clos einput */107 /* close input */ 108 108 if (NXclose (&inId) != NX_OK) 109 109 { -
trunk/src/nxdataset.c
r952 r1234 47 47 length *= dim[i]; 48 48 } 49 pNew->u.ptr = malloc(length*getTypeSize(typecode)); 49 /* add +1 in case of string NULL termination */ 50 pNew->u.ptr = malloc(length*getTypeSize(typecode)+1); 50 51 51 52 if(pNew->dim == NULL || pNew->u.ptr == NULL){ … … 60 61 } 61 62 pNew->magic = MAGIC; 62 memset(pNew->u.ptr,0,length*getTypeSize(typecode)); 63 /* add +1 in case of string NULL termination - see above */ 64 memset(pNew->u.ptr,0,length*getTypeSize(typecode)+1); 63 65 return pNew; 64 66 }
Note: See TracChangeset
for help on using the changeset viewer.
