Changeset 313f897 in rtems
- Timestamp:
- 09/13/18 12:50:08 (6 years ago)
- Branches:
- 5, master
- Children:
- 8777d4c
- Parents:
- 1ad43f8
- git-author:
- Sebastian Huber <sebastian.huber@…> (09/13/18 12:50:08)
- git-committer:
- Sebastian Huber <sebastian.huber@…> (10/04/18 06:02:29)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
cpukit/libcsupport/src/calloc.c
r1ad43f8 r313f897 29 29 ) 30 30 { 31 char*cptr;31 void *cptr; 32 32 size_t length; 33 33 … … 35 35 cptr = malloc( length ); 36 36 RTEMS_OBFUSCATE_VARIABLE( cptr ); 37 if ( cptr ) 38 memset( cptr, '\0', length ); 37 if ( RTEMS_PREDICT_FALSE( cptr == NULL ) ) { 38 return cptr; 39 } 39 40 40 return cptr;41 return memset( cptr, 0, length ); 41 42 } 42 43 #endif
Note: See TracChangeset
for help on using the changeset viewer.